-
Notifications
You must be signed in to change notification settings - Fork 57
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
Allow <json repr="string">
for int types
#330
Conversation
"json encoding int with string representation", test_encoding_int_with_string_repr; | ||
"json encoding & decoding int with string representation", test_encoding_decoding_int_with_string_repr; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we have a couple of tests encoding ints as ints?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks!
Hi @mjambon, would appreciate your review on this PR. Thank you |
@mjambon gentle ping. I'll be happy to address any concerns you may have about this PR 🙂 |
@sebastiantoh sorry, I didn't realize you wanted my review specifically. I reviewed the changes, it looks good to me. Let's merge it. I was wondering what happens to the target languages (Python, ...) that don't support |
@sebastiantoh and thank you! |
…n-codec-runtime and atd (2.12.0) CHANGES: * atdgen: Annotate generated code with types to disambiguate OCaml classic variants (ahrefs/atd#331) * atdpy: Support the option type more correctly so that it follows ATD's convention for JSON encoding. This allows compatibility with JSON produced by other tools of the ATD suite. The Python type, however, is still a nullable (`Optional`) to make things simpler for Python programmers. This prevents distinguishing `["Some", "None"]` from `"None"` which both translate to `None` in Python. (ahrefs/atd#332) * (BREAKING) atdgen: revert default encoding of int64 values as string (ahrefs/atd#330) * atdgen: Support `<json repr="string">` for `int` values (ahrefs/atd#330) * atdpy: Treat default field values as expressions to evaluate each time they're assigned to a field. This allows the use of mutable defaults such as lists (ahrefs/atd#339)
This PR addresses issue #273 and supersedes #291
<json repr="string">
annotation for int typesPR checklist
CHANGES.md
is up-to-date