Closed ericonr closed 8 months ago
@henriquesimoes one thing I wish I knew how to implement would be avoiding costly operations for checking things every time a mask is passed to extract_value
and get_bit
, given that they receive constant arguments which could somehow be evaluated during compilation. But adding constexpr
isn't an option if the template receives non-constant arguments anywhere.
So I'm feeling like I shouldn't skimp on these verifications, but I would like to be able to optimize them, which improves developer experience (get compile time warnings/errors) and avoids technically unnecessary run-time checks.
Ok, I'm comfortable with merging this version. Will probably do it next week so it can have some more time to stew.