au
au copied to clipboard
Improve efficiency of explicit-rep overflow checkers
Our initial implementation for #110 will have separate checks for each of 3 stages: static cast to common type, unit conversion, and static cast to destination type.
Really, there should be a simple boundary between values that won't overflow, and those that will. Therefore, a more efficient version would be to simply compute this boundary, and compare the input value to it.