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
Is your feature request related to a problem? Please describe.
The parsley.token.descriptions.SpaceDesc params commentStart and commentEnd should more clearly indicate that they are intended for multiline comments. With current naming you might try to define Wacc/Python-style comments as:
commentStart = "#",
commentEnd = "\n",
However, this should instead be defined using commentLine = "#".
Additionally, including \n in commentEnd in this case essentially causes comment lines to be discarded when calculating token positions.
Describe the solution you'd like
comment{Start,End} should be named more descriptively, for example multiLineComment{Start,End}.
Either position calculation should be fixed for comment{Start,End} containing \n, or this behaviour should be documented and produce a warning / error.
The text was updated successfully, but these errors were encountered:
This is a breaking change to the description, so I'll put it on the list for parsley 5.
Ruling out \n (and \t) in any lexical descriptions that assume that the characters are "flat" is something I can add as requirements on the descriptions for 5.0 onwards, and I might consider some kind of suppressible warning system that perhaps I can add in 4.3
Is your feature request related to a problem? Please describe.
The
parsley.token.descriptions.SpaceDesc
paramscommentStart
andcommentEnd
should more clearly indicate that they are intended for multiline comments. With current naming you might try to define Wacc/Python-style comments as:However, this should instead be defined using
commentLine = "#"
.Additionally, including
\n
incommentEnd
in this case essentially causes comment lines to be discarded when calculating token positions.Describe the solution you'd like
comment{Start,End}
should be named more descriptively, for examplemultiLineComment{Start,End}
.comment{Start,End}
containing\n
, or this behaviour should be documented and produce a warning / error.The text was updated successfully, but these errors were encountered: