We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c7611df commit 68e6f02Copy full SHA for 68e6f02
src/ShellCheck/Parser.hs
@@ -141,15 +141,9 @@ carriageReturn = do
141
parseProblemAt pos ErrorC 1017 "Literal carriage return. Run script through tr -d '\\r' ."
142
return '\r'
143
144
-almostSpace =
145
- choice [
146
- check '\xA0' "unicode non-breaking space",
147
- check '\x200B' "unicode zerowidth space"
148
- ]
149
- where
150
- check c name = do
151
- parseNote ErrorC 1018 $ "This is a " ++ name ++ ". Delete and retype it."
152
- char c
+almostSpace = do
+ parseNote ErrorC 1018 $ "This is a unicode space. Delete and retype it."
+ oneOf "\xA0\x2002\x2003\x2004\x2005\x2006\x2007\x2008\x2009\x200B\x202F"
153
return ' '
154
155
--------- Message/position annotation on top of user state
0 commit comments