File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 14
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
15
GNU General Public License for more details.
16
16
17
- yOU should have received a copy of the GNU General Public License
17
+ You should have received a copy of the GNU General Public License
18
18
along with this program. If not, see <http://www.gnu.org/licenses/>.
19
19
-}
20
20
{-# LANGUAGE NoMonomorphismRestriction, TemplateHaskell, FlexibleContexts #-}
@@ -1799,6 +1799,7 @@ prop_readSimpleCommand3 = isOk readSimpleCommand "export foo=(bar baz)"
1799
1799
prop_readSimpleCommand4 = isOk readSimpleCommand " typeset -a foo=(lol)"
1800
1800
prop_readSimpleCommand5 = isOk readSimpleCommand " time if true; then echo foo; fi"
1801
1801
prop_readSimpleCommand6 = isOk readSimpleCommand " time -p ( ls -l; )"
1802
+ prop_readSimpleCommand7 = isOk readSimpleCommand " \\ ls"
1802
1803
readSimpleCommand = called " simple command" $ do
1803
1804
pos <- getPosition
1804
1805
id1 <- getNextId
@@ -1968,7 +1969,12 @@ readCommand = choice [
1968
1969
readSimpleCommand
1969
1970
]
1970
1971
1971
- readCmdName = readCmdWord
1972
+ readCmdName = do
1973
+ -- Ignore alias suppression
1974
+ optional . try $ do
1975
+ char ' \\ '
1976
+ lookAhead $ variableChars
1977
+ readCmdWord
1972
1978
readCmdWord = readNormalWord <* spacing
1973
1979
1974
1980
prop_readIfClause = isOk readIfClause " if false; then foo; elif true; then stuff; more stuff; else cows; fi"
You can’t perform that action at this time.
0 commit comments