You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, the base2, 8, and 16 regexes don't actually enforce that there are any digits in the number! i.e. these should all be parsed as numeric literals in plain-style, allegedly:
0b_
0_
0x_
However, they of course don't actually represent a number at all.
I gather this isn't a problem in YAML 1.2 because _ isn't allowed in numeric literals there at all. But should there be some kind of errata published for the YAML 1.1 !int type to tighten up these regular expressions?
This was raised as an issue with Psych (ruby/psych#687), but I guess this is actually a specification issue so I thought I'd bring it up here as well.
The YAML 1.1
!int
type says that:However, the base2, 8, and 16 regexes don't actually enforce that there are any digits in the number! i.e. these should all be parsed as numeric literals in plain-style, allegedly:
0b_
0_
0x_
However, they of course don't actually represent a number at all.
I gather this isn't a problem in YAML 1.2 because
_
isn't allowed in numeric literals there at all. But should there be some kind of errata published for the YAML 1.1!int
type to tighten up these regular expressions?@zendesk-jmeade suggested in the linked Psych issue:
The text was updated successfully, but these errors were encountered: