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
The README mentions unit_t::to<T> and unit_cast<T> for accessing the underlying value as T. However the implementation of these seem to be using static_cast<T> internally, and (due to an unit_t::operator T() I guess?) it works externally too.
Is using static_cast for accessing the underlying value considered non-idiomatic? Are there any pitfalls I should be aware of when using static_cast?
The text was updated successfully, but these errors were encountered:
The README mentions
unit_t::to<T>
andunit_cast<T>
for accessing the underlying value asT
. However the implementation of these seem to be usingstatic_cast<T>
internally, and (due to anunit_t::operator T()
I guess?) it works externally too.Is using static_cast for accessing the underlying value considered non-idiomatic? Are there any pitfalls I should be aware of when using static_cast?
The text was updated successfully, but these errors were encountered: