simple-binary-encoding
simple-binary-encoding copied to clipboard
[Java/C++/C#] Fix a bug in overzealous DTO validation
Previously, in Java, the generated validation methods would not permit the null value, even for fields with optional presence. Now, we do allow these correctly.
In this change, I've also attempted to clean up, centralise, and test the logic that decides when validation for a particular side of a range needs to be included. We omit the validation when the native type cannot represent values outside of the range.
There are still some gaps around validation, e.g., we do not validate array values.