Skip to content
Snippets Groups Projects
Commit f9f4bcb0 authored by Christoph Grüninger's avatar Christoph Grüninger
Browse files

Merge branch 'feature/fieldmatrix-from-scalar' into 'master'

FieldMatrix: Allow copy construction from scalar

See also !52.

See merge request !140
parents 6f24c48e 14c97c79
No related branches found
No related tags found
No related merge requests found
......@@ -100,7 +100,7 @@ namespace Dune
template <typename T,
typename = std::enable_if_t<Dune::IsNumber<T>::value>>
explicit FieldMatrix (T scalar)
FieldMatrix (T scalar)
{
*this = scalar;
}
......
......@@ -87,8 +87,6 @@ bool run() {
{
M fieldT;
fieldT = constant;
// Intentionally disabled: ( compile-time size mismatch )
// fieldT = Dune::FieldMatrix<ft, 1, 1>(constant);
}
// Copy construction
......@@ -109,9 +107,7 @@ bool run() {
}
}
{
DUNE_UNUSED M const fieldT(constant);
// Intentionally disabled:
// M const fieldT2 = constant;
DUNE_UNUSED M const fieldT = constant;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment