Upstream FieldTraits specialization and possibly propose default typedef changes
https://git.imp.fu-berlin.de/agnumpde/dune-matrix-vector/blob/master/dune/matrix-vector/traits/fieldtraits.hh
(which currently only specializes FieldTraits
for ScaledIdentityMatrix
) should be upstreamed to dune-istl
, since it requires special knowledge that this file should be included to get the expected field_t
- and FieldTraits
-behaviour.
Unfortunately, the default typedefs in FieldTraits
(dune-common
:https://gitlab.dune-project.org/core/dune-common/blob/master/dune/common/ftraits.hh) are also chosen awkwardly IMHO, as they serve as a recursion anchor for nested types, but do not provide insightful compiling errors when used on unspecialized types (like above). I'd rather see some enable_if<is_arithmetic<T>>
-like recursion anchor there as well.