Added numeric digits over the HR codes#720
Conversation
|
Thank you for catching this, hovever not only codes but every VTL identifier can start with a number. I would keep the parser grammar the same, but change only the IDENTIFIER rule from: to |
|
Good point @javihern98 , @vpinna80 , I agree, it's good in terms of IDENTIFIER |
|
After testing seems the proper fix would look like this (the proposal from @vpinna80 had missing the underscore in the second group): @vpinna80 @NicoLaval Would you agree? I will make the changes in this branch with this |
|
That is not a mistake, unfortunately: The regular names:
This means that neither |
Summary
VTL 2.1 accepted Code Item values starting with a digit (e.g. 1AA) in hierarchical rulesets, because its IDENTIFIER token allowed digit-leading names. In 2.2 IDENTIFIER was narrowed to letter/underscore-leading (for SDMX ids, e0ae21e), which also dropped these codes. This restores the 2.1 behaviour for hierarchical-ruleset code items only, without re-widening IDENTIFIER globally.
Example
Now parses under 2.2 (previously failed — 1AA lexed as 1 + AA):
Changes