• File: plyparser.cpython-37.pyc
  • Full Path: /home3/farmfre2/public_html/ALFA_DATA/alfasymlink/root/opt/alt/python37/lib/python3.7/site-packages/pycparser/__pycache__/plyparser.cpython-37.pyc
  • Date Modified: 07/07/2021 11:53 PM
  • File size: 2.03 KB
  • MIME-type: text/x-bytecode.python
  • Charset: 8 bit
B

>`:@s4GdddeZGdddeZGdddeZdS)c@s&eZdZdZdZdddZddZdS)	Coordz Coordinates of a syntactic element. Consists of:
            - File name
            - Line number
            - (optional) column number, for the Lexer
    )filelinecolumn__weakref__NcCs||_||_||_dS)N)rrr)selfrrrrD/opt/alt/python37/lib/python3.7/site-packages/pycparser/plyparser.py__init__szCoord.__init__cCs(d|j|jf}|jr$|d|j7}|S)Nz%s:%sz:%s)rrr)rstrrrr__str__sz
Coord.__str__)N)__name__
__module____qualname____doc__	__slots__r	rrrrrrs
rc@seZdZdS)
ParseErrorN)rr
rrrrrrsrc@s&eZdZddZdddZddZdS)		PLYParsercCs<|d}dd}d||f|_d||_t|j|j|dS)z Given a rule name, creates an optional ply.yacc rule
            for it. The name of the optional rule is
            <rulename>_opt
        Z_optcSs|d|d<dS)Nr)rprrroptrule)sz+PLYParser._create_opt_rule.<locals>.optrulez%s : empty
| %szp_%sN)rrsetattr	__class__)rZrulenameZoptnamerrrr_create_opt_rule"s

zPLYParser._create_opt_ruleNcCst|jj||dS)N)rrr)rZclexfilename)rlinenorrrr_coord0szPLYParser._coordcCstd||fdS)Nz%s: %s)r)rmsgZcoordrrr_parse_error6szPLYParser._parse_error)N)rr
rrrrrrrrr!s
rN)objectr	Exceptionrrrrrr<module>s