mirror of
https://git.FreeBSD.org/src.git
synced 2024-11-29 08:08:37 +00:00
sh: Add test for $'\u' without any digits.
It is likely that $'\uXXXX' and $'\UXXXXXXXX' will allow fewer digits in future. However, no digits at all should still be disallowed.
This commit is contained in:
parent
a6bf3a9ef6
commit
f84460dded
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=286971
@ -36,6 +36,7 @@ FILES+= dollar-quote8.0
|
|||||||
FILES+= dollar-quote9.0
|
FILES+= dollar-quote9.0
|
||||||
FILES+= dollar-quote10.0
|
FILES+= dollar-quote10.0
|
||||||
FILES+= dollar-quote11.0
|
FILES+= dollar-quote11.0
|
||||||
|
FILES+= dollar-quote12.0
|
||||||
FILES+= empty-braces1.0
|
FILES+= empty-braces1.0
|
||||||
FILES+= empty-cmd1.0
|
FILES+= empty-cmd1.0
|
||||||
FILES+= for1.0
|
FILES+= for1.0
|
||||||
|
7
bin/sh/tests/parser/dollar-quote12.0
Normal file
7
bin/sh/tests/parser/dollar-quote12.0
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# $FreeBSD$
|
||||||
|
|
||||||
|
# \u without any digits at all remains invalid.
|
||||||
|
# Our choice is a parse error.
|
||||||
|
|
||||||
|
v=$( (eval ": \$'\u'") 2>&1 >/dev/null)
|
||||||
|
[ $? -ne 0 ] && [ -n "$v" ]
|
Loading…
Reference in New Issue
Block a user