-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Union types should allow "null" in any position #39
Comments
I think the reason for the current implementation is the following text from the spec: But I agree that it could be improved to support your use case. And the spec says I will send a PR! |
Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
This crate will make the conservative approach of using "null" only in first position as otherwise things get really too complicated. |
(Although this can be reconsidered later, when the spec is clearer, and when it's supported in |
Using the following schema:
rsgen-avro errors with:
I don't see a requirement in the avro spec about this (we do have additional requirements when we have a default value, but this doesn't apply here).
The text was updated successfully, but these errors were encountered: