For now, I'm just preserving the same semantics of the previous implementations, just putting the assertion at the end instead of up front. Are you ok with a better error message? Ideally all of these methods would return some form of result rather than fail, but that would require a larger rewrite I think.