This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Distinguish C- and perly- literals - PERLY_PAREN_OPEN
[perl5.git] / perly.h
CommitLineData
e8fb9efb
NC
1/* -*- buffer-read-only: t -*-
2 !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
3f5e9543 3 This file is built by regen_perly.pl from perly.y.
e8fb9efb
NC
4 Any changes made here will be lost!
5 */
6
53443c95 7#define PERL_BISON_VERSION 30005
f39ff1f3 8
d8118cad 9#ifdef PERL_CORE
53443c95 10/* A Bison parser, made by GNU Bison 3.5.1. */
4e4da3ac 11
a9f5ab8d 12/* Bison interface for Yacc-like parsers in C
38c8d7b1 13
53443c95 14 Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2020 Free Software Foundation,
a3815e44 15 Inc.
38c8d7b1 16
a9f5ab8d 17 This program is free software: you can redistribute it and/or modify
0de566d7 18 it under the terms of the GNU General Public License as published by
a9f5ab8d
LM
19 the Free Software Foundation, either version 3 of the License, or
20 (at your option) any later version.
38c8d7b1 21
0de566d7
DM
22 This program is distributed in the hope that it will be useful,
23 but WITHOUT ANY WARRANTY; without even the implied warranty of
24 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 GNU General Public License for more details.
38c8d7b1 26
0de566d7 27 You should have received a copy of the GNU General Public License
a9f5ab8d 28 along with this program. If not, see <http://www.gnu.org/licenses/>. */
0de566d7 29
f05e27e5
DM
30/* As a special exception, you may create a larger work that contains
31 part or all of the Bison parser skeleton and distribute that work
32 under terms of your choice, so long as that work isn't itself a
33 parser generator using the skeleton or a modified version thereof
34 as a parser skeleton. Alternatively, if you modify or redistribute
35 the parser skeleton itself, you may (at your option) remove this
36 special exception, which will cause the skeleton and the resulting
37 Bison output files to be licensed under the GNU General Public
38 License without this special exception.
38c8d7b1 39
f05e27e5
DM
40 This special exception was added by the Free Software Foundation in
41 version 2.2 of Bison. */
0de566d7 42
a3815e44
DIM
43/* Undocumented macros, especially those whose name start with YY_,
44 are private implementation details. Do not rely on them. */
45
a9f5ab8d
LM
46/* Debug traces. */
47#ifndef YYDEBUG
48# define YYDEBUG 0
49#endif
50#if YYDEBUG
51extern int yydebug;
52#endif
53
54/* Token type. */
0de566d7
DM
55#ifndef YYTOKENTYPE
56# define YYTOKENTYPE
a9f5ab8d
LM
57 enum yytokentype
58 {
59 GRAMPROG = 258,
60 GRAMEXPR = 259,
61 GRAMBLOCK = 260,
62 GRAMBARESTMT = 261,
63 GRAMFULLSTMT = 262,
64 GRAMSTMTSEQ = 263,
996b0cb8 65 GRAMSUBSIGNATURE = 264,
25a50500
BZ
66 PERLY_AMPERSAND = 265,
67 PERLY_BRACE_OPEN = 266,
68 PERLY_BRACE_CLOSE = 267,
69 PERLY_BRACKET_OPEN = 268,
70 PERLY_BRACKET_CLOSE = 269,
581f9a7a
BZ
71 PERLY_COMMA = 270,
72 PERLY_DOT = 271,
73 PERLY_EQUAL_SIGN = 272,
68a66a8b 74 PERLY_MINUS = 273,
0ba95c59
BZ
75 PERLY_PERCENT_SIGN = 274,
76 PERLY_PLUS = 275,
77 PERLY_SEMICOLON = 276,
78 PERLY_SNAIL = 277,
79 BAREWORD = 278,
80 METHOD = 279,
81 FUNCMETH = 280,
82 THING = 281,
83 PMFUNC = 282,
84 PRIVATEREF = 283,
85 QWLIST = 284,
86 FUNC0OP = 285,
87 FUNC0SUB = 286,
88 UNIOPSUB = 287,
89 LSTOPSUB = 288,
90 PLUGEXPR = 289,
91 PLUGSTMT = 290,
92 LABEL = 291,
93 FORMAT = 292,
94 SUB = 293,
95 SIGSUB = 294,
96 ANONSUB = 295,
97 ANON_SIGSUB = 296,
98 PACKAGE = 297,
99 USE = 298,
100 WHILE = 299,
101 UNTIL = 300,
102 IF = 301,
103 UNLESS = 302,
104 ELSE = 303,
105 ELSIF = 304,
106 CONTINUE = 305,
107 FOR = 306,
108 GIVEN = 307,
109 WHEN = 308,
110 DEFAULT = 309,
111 LOOPEX = 310,
112 DOTDOT = 311,
113 YADAYADA = 312,
114 FUNC0 = 313,
115 FUNC1 = 314,
116 FUNC = 315,
117 UNIOP = 316,
118 LSTOP = 317,
119 MULOP = 318,
120 ADDOP = 319,
121 DOLSHARP = 320,
122 DO = 321,
123 HASHBRACK = 322,
124 NOAMP = 323,
125 LOCAL = 324,
126 MY = 325,
127 REQUIRE = 326,
128 COLONATTR = 327,
129 FORMLBRACK = 328,
130 FORMRBRACK = 329,
131 SUBLEXSTART = 330,
132 SUBLEXEND = 331,
133 PREC_LOW = 332,
134 OROP = 333,
135 DOROP = 334,
136 ANDOP = 335,
137 NOTOP = 336,
138 ASSIGNOP = 337,
139 PERLY_QUESTION_MARK = 338,
140 PERLY_COLON = 339,
141 OROR = 340,
142 DORDOR = 341,
143 ANDAND = 342,
144 BITOROP = 343,
145 BITANDOP = 344,
146 CHEQOP = 345,
147 NCEQOP = 346,
148 CHRELOP = 347,
149 NCRELOP = 348,
150 SHIFTOP = 349,
151 MATCHOP = 350,
152 PERLY_EXCLAMATION_MARK = 351,
153 PERLY_TILDE = 352,
154 UMINUS = 353,
155 REFGEN = 354,
156 POWOP = 355,
157 PREINC = 356,
158 PREDEC = 357,
159 POSTINC = 358,
160 POSTDEC = 359,
161 POSTJOIN = 360,
ee67f254
BZ
162 ARROW = 361,
163 PERLY_PAREN_OPEN = 362
a9f5ab8d 164 };
0de566d7 165#endif
38c8d7b1 166
a9f5ab8d 167/* Value type. */
6c7ae946
FC
168#ifdef PERL_IN_TOKE_C
169static bool
170S_is_opval_token(int type) {
171 switch (type) {
185c2e96 172 case BAREWORD:
6c7ae946
FC
173 case FUNC0OP:
174 case FUNC0SUB:
175 case FUNCMETH:
01719201 176 case LABEL:
6c7ae946
FC
177 case LSTOPSUB:
178 case METHOD:
179 case PLUGEXPR:
180 case PLUGSTMT:
181 case PMFUNC:
182 case PRIVATEREF:
183 case QWLIST:
184 case THING:
185 case UNIOPSUB:
6c7ae946
FC
186 return 1;
187 }
188 return 0;
189}
190#endif /* PERL_IN_TOKE_C */
0de566d7 191#endif /* PERL_CORE */
f05e27e5 192#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
a9f5ab8d 193union YYSTYPE
f05e27e5 194{
a9f5ab8d 195
d5c6462e
DM
196 I32 ival; /* __DEFAULT__ (marker for regen_perly.pl;
197 must always be 1st union member) */
79072805
LW
198 char *pval;
199 OP *opval;
200 GV *gvval;
a9f5ab8d 201
a3815e44 202
53443c95 203};
a3815e44 204typedef union YYSTYPE YYSTYPE;
bdc377e5 205# define YYSTYPE_IS_TRIVIAL 1
a9f5ab8d 206# define YYSTYPE_IS_DECLARED 1
0de566d7
DM
207#endif
208
209
210
a9f5ab8d
LM
211int yyparse (void);
212
e8fb9efb 213
c24c946d 214/* Generated from:
ee67f254 215 * 8e3bd7759e3e39aabe8c75614ea5d1a9188a7196abaee7d2164e9b3b14fb38d6 perly.y
53443c95 216 * acf1cbfd2545faeaaa58b1cf0cf9d7f98b5be0752eb7a54528ef904a9e2e1ca7 regen_perly.pl
c24c946d 217 * ex: set ro: */