Пример #1
0
 def dictionary(self):    
     d = None
     
     try:      ## for error handling
         pass
         self.match(LCURLY)
         self.match(RCURLY)
         d = Node(None, "dictionary"); d._internal_data = {}
     
     except antlr.RecognitionException, ex:
         self.reportError(ex)
         self.consume()
         self.consumeUntil(_tokenSet_1)
Пример #2
0
    def dictionary(self):
        d = None

        try:  ## for error handling
            pass
            self.match(LCURLY)
            self.match(RCURLY)
            d = Node(None, "dictionary")
            d._internal_data = {}

        except antlr.RecognitionException, ex:
            self.reportError(ex)
            self.consume()
            self.consumeUntil(_tokenSet_1)