# HG changeset patch # User Catherine Devlin # Date 1239224533 14400 # Node ID 584f970ca66a35ad876d4f8bfce09b916a8186a6 # Parent ba45c2df855b34b5ac7b04f459fec8058848e631 permit bare prefix diff -r ba45c2df855b -r 584f970ca66a cmd2.py --- a/cmd2.py Fri Apr 03 13:04:39 2009 -0400 +++ b/cmd2.py Wed Apr 08 17:02:13 2009 -0400 @@ -508,12 +508,12 @@ #self.multilineParser = self.multilineParser.setResultsName('multilineParser') #self.singleLineParser = self.singleLineParser.setResultsName('singleLineParser') #self.blankLineTerminationParser = self.blankLineTerminationParser.setResultsName('blankLineTerminatorParser') - self.parser = ( + self.parser = self.prefixParser + ( stringEnd | - self.prefixParser + self.multilineParser | - self.prefixParser + self.singleLineParser | - self.prefixParser + self.blankLineTerminationParser | - self.prefixParser + self.multilineCommand + pyparsing.SkipTo(stringEnd) + self.multilineParser | + self.singleLineParser | + self.blankLineTerminationParser | + self.multilineCommand + pyparsing.SkipTo(stringEnd) ) self.parser.ignore(pyparsing.quotedString).ignore(self.commentGrammars)