]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Bugfix: Add additional braces around subobject initializers..
authorMatthias Maier <tamiko@43-1.org>
Thu, 29 Oct 2015 03:31:06 +0000 (22:31 -0500)
committerMatthias Maier <tamiko@43-1.org>
Thu, 29 Oct 2015 03:36:26 +0000 (22:36 -0500)
Hopefully this makes icc happy

tests/base/tensor_accessors_02.cc
tests/lac/block_linear_operator_01.cc
tests/lac/block_linear_operator_02.cc

index 965ad27e7902fb6f6b7cf9e0e9a24fc9e08179e3..2e7880b3b01ce5bfffc48c55ec68e49bed7459d7 100644 (file)
@@ -78,7 +78,7 @@ int main()
 
     // via std::array:
 #ifdef DEAL_II_WITH_CXX11
-    std::array<unsigned int, 5> temp {2, 1, 0, 2, 1};
+    std::array<unsigned int, 5> temp {{2, 1, 0, 2, 1}};
     deallog << TensorAccessors::extract<5>(foo, temp) << std::endl;
 #else
     deallog << 42. << std::endl;
index 7bf25fe531fbff14b26ee80d3842d264207caccb..75d622e0e91121f7eee80bf29e78855d2dd0ccec 100644 (file)
@@ -107,9 +107,8 @@ int main()
   auto op_b10 = linear_operator(a.block(1, 0));
   auto op_b11 = linear_operator(a.block(1, 1));
 
-  std::array<std::array<decltype(op_b00), 2>, 2> temp {op_b00, op_b01, op_b10,
-                                                       op_b11
-                                                      };
+  std::array<std::array<decltype(op_b00), 2>, 2> temp{
+      {op_b00, op_b01, op_b10, op_b11}};
   auto op_b = block_operator<2, 2, BlockVector<double>>(temp);
 
   {
@@ -185,10 +184,8 @@ int main()
 
   // And finally complicated block structures:
 
-  std::array<std::array<decltype(op_b00), 3>, 3> temp2
-  {
-    op_b00, op_b01, op_b00, op_b10, op_b11, op_b10, op_b10, op_b11, op_b10
-  };
+  std::array<std::array<decltype(op_b00), 3>, 3> temp2{
+      {op_b00, op_b01, op_b00, op_b10, op_b11, op_b10, op_b10, op_b11, op_b10}};
   auto op_upp_x_upu = block_operator<3, 3, BlockVector<double>>(temp2);
 
   op_upp_x_upu.reinit_domain_vector(u, false);
@@ -206,10 +203,12 @@ int main()
   op_upp_x_upu.vmult_add(v, u);
   PRINTME("v", v);
 
-  std::array<std::array<decltype(op_b01), 1>, 3> temp3 {op_b01, op_b11, op_b11};
+  std::array<std::array<decltype(op_b01), 1>, 3> temp3{
+      {op_b01, op_b11, op_b11}};
   auto op_upp_x_p = block_operator<3, 1, BlockVector<double>>(temp3);
 
-  std::array<std::array<decltype(op_b01), 3>, 1> temp4 {op_b00, op_b01, op_b00};
+  std::array<std::array<decltype(op_b01), 3>, 1> temp4{
+      {op_b00, op_b01, op_b00}};
   auto op_u_x_upu = block_operator<1, 3, BlockVector<double>>(temp4);
 
   auto op_long = op_u_x_upu * transpose_operator(op_upp_x_upu) * op_upp_x_p;
index 6fe6df9a82cbc4f760a262ac4b8a32967cef2c93..55cacb8641cd2983bf8b336221820675c5af90a1 100644 (file)
@@ -84,8 +84,7 @@ int main()
   auto op_b1 = linear_operator(a.block(1, 1));
   auto op_b2 = linear_operator(a.block(2, 2));
 
-
-  std::array<decltype(op_b0), 3> temp {op_b0, op_b1, op_b2};
+  std::array<decltype(op_b0), 3> temp{{op_b0, op_b1, op_b2}};
   auto op_b = block_diagonal_operator<3, BlockVector<double>>(temp);
 
 
@@ -157,7 +156,7 @@ int main()
 
   // And finally the other block_diagonal_operator variant:
 
-  std::array<decltype(op_b0), 5> temp2 {op_b0, op_b0, op_b0, op_b0, op_b0};
+  std::array<decltype(op_b0), 5> temp2{{op_b0, op_b0, op_b0, op_b0, op_b0}};
   auto op_c = block_diagonal_operator<5, BlockVector<double>>(temp2);
 
   auto op_d = block_diagonal_operator<5, BlockVector<double>>(op_b0);

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.