]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Work around a bug in old gccs.
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 22 Oct 2003 23:50:43 +0000 (23:50 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 22 Oct 2003 23:50:43 +0000 (23:50 +0000)
git-svn-id: https://svn.dealii.org/trunk@8136 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/fe/mapping_q.cc

index 89f194d1c4b86f0ec90093ad8f108f41d03710eb..6117836c10283ef778990fccdb4174807117cbac 100644 (file)
@@ -872,11 +872,24 @@ add_quad_support_points(const Triangulation<3>::cell_iterator &cell,
                                        // for the present face
       const bool face_orientation = cell->face_orientation(face_no);
 
+                                       // work around a bug in older
+                                       // gcc versions (2.95) when an
+                                       // array in a conditional
+                                       // decays too quickly to a
+                                       // pointer
+#ifndef DEAL_II_ARRAY_CONDITIONAL_DECAY_BUG      
       const unsigned int (&face_vertex_to_cell_vertex)[vertices_per_face]
+#else
+      const unsigned int *face_vertex_to_cell_vertex
+#endif
         = (face_orientation ?
            face_vertex_to_cell_vertex1[face_no] :
            face_vertex_to_cell_vertex2[face_no]);
+#ifndef DEAL_II_ARRAY_CONDITIONAL_DECAY_BUG      
       const unsigned int (&face_line_to_cell_line)[lines_per_face]
+#else
+      const unsigned int *face_line_to_cell_line
+#endif
         = (face_orientation ?
            face_line_to_cell_line1[face_no] :
            face_line_to_cell_line2[face_no]);

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.