> I am getting this strange compile error with deal.II subversion:
> 
> ======================debug======MT==
> numerics/derivative_approximation.cc In file included
> from
> /home/tyoung/research.code/deal.II/source/numerics/derivative_approximatio
> n.cc:23:
> /home/tyoung/research.code/deal.II/include/deal.II/grid/grid_tools.h:79:
> error: ‘spacedim’ is not a
> type
> [...] 
> The offending line (79) is:
>     template <int dim, int spacedim>
>     static
>     double volume (const Triangulation<dim,spacedim> &tria,
>                    const Mapping<dim,spacedim> &mapping =
>                    StaticMappingQ1<dim,spacedim>::mapping);

Thanks for pointing it out, I've fixed this. The problem is that older C++ 
compilers can distinguish
  void f (X &x = S<dim,spacedim>::x);
(1 argument x, with default S<dim,spacedim>::x) from
  void f(X &x = S<dim,
            spacedim >:: x);
(2 arguments, the first with a nonsensical default value "S<dim" and the next 
one completely garbled). The solution is to write this as
  void f (X &x = (S<dim,spacedim>::x));

Cheers
 W.

-------------------------------------------------------------------------
Wolfgang Bangerth                email:            [email protected]
                                 www: http://www.math.tamu.edu/~bangerth/
_______________________________________________
dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii

Reply via email to