lexer: temporarily revert #\ patch; keep CR in comment bug fix

This commit temporarily reverts the commit that allows #\ "tcl-style"
comments everywhere and documents them, for the 1.7.1 patch release
cca1f7d18f.

\r is removed from the list of characters not allowed in a comment to
preserve that bugfix.
This commit is contained in:
Emanuele Torre authored and GitHub committed 2023-12-13 16:38:18 +01:00
1 parent 511d50b15b
commit 5d95791a67
7 files changed
+279 -440

No files matched your search

-18
View File
@@ -594,24 +594,6 @@ if ! x=$($JQ -n "1 # foo$cr + 2") || [ "$x" != 1 ]; then
exit 1
fi
if ! x=$($JQ -cn '[
1,
# foo \
2,
# bar \\
3,
4, # baz \\\
5, \
6,
7
# comment \
comment \
comment
]') || [ "$x" != '[1,3,4,7]' ]; then
echo 'multiline comment was not handled correctly'
exit 1
fi
# Allow passing the inline jq script before -- #2919
if ! r=$($JQ --args -rn -- '$ARGS.positional[0]' bar) || [ "$r" != bar ]; then
echo "passing the inline script after -- didn't work"