Closed chrysn closed 2 months ago
It is slightly weird that app-string resolvers that implement nan'...' will need to output non-basic EDN, but otherwise I'm fine with leaving this to an app-extension -- I'd rather have a use case in hand for which we design this.
(The syntax clash between NaN
and nan'foo'
worries me slightly in case we ever get rid of required commas, but that has to be solved there.)
Thanks, then let's close this.
The weirdness of producing non-basic EDN is a tad odd, but given that implementers may choose to also treat h, b64 & co as application oriented literals, they may already be familiar with the situation, because other than through those they can't produce non-UTF8 binary strings.
As part of working on an implementation, I noted that NaN payloads are not expressible -- a diag2cbor can take
NaN
to meanF9 7E00
, but if I findF9 7E01
I can't express this in EDN without losing information.I think that's OK because NaN payloads are a niche case, and because there is the extension point of specifying a
nan'7e00'
literal (with the caveat that while most other literals can be turned into a non-application-literal form, this one can't, so EDN libraries may need to support it internally rather than through an extension point). Still would like to confirm that this is an intentional elision.