(self, tokens)
Called recursively within nested #if(n)def... #else... #endif blocks.
Called recursively within nested #if(n)def... #else... #endif blocks.
Called recursively within nested #if ( n ) def ... #else ... #endif blocks .
def recurse_into_conditionals(self, tokens):
    """Called recursively within nested #if(n)def... #else... #endif blocks."""
    for token in tokens:
      # Another nested conditional block
      if token.predicate:
        if (token.predicate in self.get_consts_and_enums()
            and self.get_consts_and_enums()[token.predicate]):
          self.recurse_into_conditionals(token.if_true)
        else:
          self.recurse_into_conditionals(token.if_false)
      # One or more declarations
      else:
        if token.typename:
          self.typedefs_dict.update({token.name: token.typename})
        elif token.value:
          value = codegen_util.try_coerce_to_num(token.value)
          # Avoid adding function aliases.
          if isinstance(value, str):
            continue
          else:
            self.consts_dict.update({token.name: value})
        else:
          self.consts_dict.update({token.name: True})
def recurse_into_conditionals ( self , tokens ) : for token in tokens : # Another nested conditional block if token . predicate : if ( token . predicate in self . get_consts_and_enums ( ) and self . get_consts_and_enums ( ) [ token . predicate ] ) : self . recurse_into_conditionals ( token . if_true ) else : self . recurse_into_conditionals ( token . if_false ) # One or more declarations else : if token . typename : self . typedefs_dict . update ( { token . name : token . typename } ) elif token . value : value = codegen_util . try_coerce_to_num ( token . value ) # Avoid adding function aliases. if isinstance ( value , str ) : continue else : self . consts_dict . update ( { token . name : value } ) else : self . consts_dict . update ( { token . name : True } )