You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was looking at the class in include/dca/phys/domains/convert.hpp as it gave me problems with changes to variadic template helpers and got quite confused.
Why do we have all this machinery, a generic class convert<To, From> which is specialized only from electron band and spin to the spin_band domain, using static memory allocations and template overloading while a simple function return band + BDmn::dmn_size() + to_coordinate(spin) would suffice?
There is this if condition:
if (std::is_same<dca::util::TypeAt<0, parameter_typelist>::type, domains::electron_band_domain>::value)
which trivially evaluates to true for how the code is written. It seems like its only purpose is to confuse the reader.
Can I remove it, and possibly remove the whole class for a single, non templated function call?
The text was updated successfully, but these errors were encountered:
I was looking at the class in include/dca/phys/domains/convert.hpp as it gave me problems with changes to variadic template helpers and got quite confused.
Why do we have all this machinery, a generic class convert<To, From> which is specialized only from electron band and spin to the spin_band domain, using static memory allocations and template overloading while a simple function
return band + BDmn::dmn_size() + to_coordinate(spin)
would suffice?There is this if condition:
which trivially evaluates to true for how the code is written. It seems like its only purpose is to confuse the reader.
Can I remove it, and possibly remove the whole class for a single, non templated function call?
The text was updated successfully, but these errors were encountered: