Avoid nesting of SubspaceBasis by resolving nested ones
While it is technically allowed and possible to construct a nested
SubspaceBasis
this is often not intended. This patch avoids such
nesting when using the subspaceBasis() method by joining the
inner and outer prefixPath
and applying it to the root of the root.
Notice that it is still possible to create a nested SubspaceBasis
by avoiding the utility function. There are a few potential caveats
of this patch:
- It's an incompatible interface change.
- Currently only one level of nesting is resolved. But that's enough
if you always use the
subspaceBasis()
method to create aSubspaceBasis
- Due to automatic class template deduction you can also directly call
SubspaceBasis(basis, path)
and it currently gives the same result assubspaceBasis(basis, path)
. This is no longer the case with this patch, because it's not possible to resolve nesting in the former case.