Mercurial > python-cmd2
diff cmd2.py @ 225:061db156c99f
tying loose ends from the day
author | catherine@dellzilla |
---|---|
date | Thu, 19 Mar 2009 17:34:21 -0400 |
parents | 0a7e97f79a60 |
children | a64555659169 82b6e0881b78 |
line wrap: on
line diff
--- a/cmd2.py Thu Mar 19 06:00:08 2009 -0400 +++ b/cmd2.py Thu Mar 19 17:34:21 2009 -0400 @@ -283,7 +283,9 @@ prefixParser = pyparsing.Empty() commentGrammars = pyparsing.Or([pyparsing.pythonStyleComment, pyparsing.cStyleComment]) commentGrammars.addParseAction(lambda x: '') - commentInProgress = pyparsing.Literal('/*') + pyparsing.SkipTo(pyparsing.stringEnd) + commentInProgress = ((pyparsing.White() | pyparsing.lineStart) + + pyparsing.Literal('/*') + pyparsing.SkipTo(pyparsing.stringEnd)) + # `blah/*` means `everything in directory `blah`, not comment terminators = [';'] blankLinesAllowed = False multilineCommands = []