GDB (xrefs)
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Enumerations | Functions | Variables
f-exp.c File Reference
#include "defs.h"
#include "expression.h"
#include "value.h"
#include "parser-defs.h"
#include "language.h"
#include "f-lang.h"
#include "block.h"
#include <ctype.h>
#include <algorithm>
#include "type-stack.h"
#include "f-exp.h"
#include "yy-remap.h"
#include <limits.h>

Go to the source code of this file.

Classes

union  f_exp_YYSTYPE
 
union  f_exp_yyalloc
 
struct  f_token
 
struct  f77_boolean_val
 

Macros

#define YYBISON   30802
 
#define YYBISON_VERSION   "3.8.2"
 
#define YYSKELETON_NAME   "yacc.c"
 
#define YYPURE   0
 
#define YYPUSH   0
 
#define YYPULL   1
 
#define parse_type(ps)   builtin_type (ps->gdbarch ())
 
#define parse_f_type(ps)   builtin_f_type (ps->gdbarch ())
 
#define GDB_YY_REMAP_PREFIX   f_
 
#define YY_CAST(Type, Val)   ((Type) (Val))
 
#define YY_REINTERPRET_CAST(Type, Val)   ((Type) (Val))
 
#define YY_NULLPTRPTR   ((void*)0)
 
#define YYTOKENTYPE
 
#define YYEMPTY   -2
 
#define YYEOF   0
 
#define YYerror   256
 
#define YYUNDEF   257
 
#define INT   258
 
#define FLOAT   259
 
#define STRING_LITERAL   260
 
#define BOOLEAN_LITERAL   261
 
#define NAME   262
 
#define TYPENAME   263
 
#define COMPLETE   264
 
#define NAME_OR_INT   265
 
#define SIZEOF   266
 
#define KIND   267
 
#define ERROR   268
 
#define INT_S1_KEYWORD   269
 
#define INT_S2_KEYWORD   270
 
#define INT_KEYWORD   271
 
#define INT_S4_KEYWORD   272
 
#define INT_S8_KEYWORD   273
 
#define LOGICAL_S1_KEYWORD   274
 
#define LOGICAL_S2_KEYWORD   275
 
#define LOGICAL_KEYWORD   276
 
#define LOGICAL_S4_KEYWORD   277
 
#define LOGICAL_S8_KEYWORD   278
 
#define REAL_KEYWORD   279
 
#define REAL_S4_KEYWORD   280
 
#define REAL_S8_KEYWORD   281
 
#define REAL_S16_KEYWORD   282
 
#define COMPLEX_KEYWORD   283
 
#define COMPLEX_S4_KEYWORD   284
 
#define COMPLEX_S8_KEYWORD   285
 
#define COMPLEX_S16_KEYWORD   286
 
#define BOOL_AND   287
 
#define BOOL_OR   288
 
#define BOOL_NOT   289
 
#define SINGLE   290
 
#define DOUBLE   291
 
#define PRECISION   292
 
#define CHARACTER   293
 
#define DOLLAR_VARIABLE   294
 
#define ASSIGN_MODIFY   295
 
#define UNOP_INTRINSIC   296
 
#define BINOP_INTRINSIC   297
 
#define UNOP_OR_BINOP_INTRINSIC   298
 
#define UNOP_OR_BINOP_OR_TERNOP_INTRINSIC   299
 
#define ABOVE_COMMA   300
 
#define EQUAL   301
 
#define NOTEQUAL   302
 
#define LESSTHAN   303
 
#define GREATERTHAN   304
 
#define LEQ   305
 
#define GEQ   306
 
#define LSH   307
 
#define RSH   308
 
#define STARSTAR   309
 
#define UNARY   310
 
#define f_exp_YYSTYPE_IS_TRIVIAL   1
 
#define f_exp_YYSTYPE_IS_DECLARED   1
 
#define YYPTRDIFF_T   long
 
#define YYPTRDIFF_MAXIMUM   LONG_MAX
 
#define YYSIZE_T   unsigned
 
#define YYSIZE_MAXIMUM
 
#define YYSIZEOF(X)   YY_CAST (YYPTRDIFF_T, sizeof (X))
 
#define YY_(Msgid)   Msgid
 
#define YY_ATTRIBUTE_PURE
 
#define YY_ATTRIBUTE_UNUSED
 
#define YY_USE(E)   ((void) (E))
 
#define YY_INITIAL_VALUE(Value)   Value
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_END
 
#define YY_IGNORE_USELESS_CAST_BEGIN
 
#define YY_IGNORE_USELESS_CAST_END
 
#define YY_ASSERT(E)   ((void) (0 && (E)))
 
#define YYSTACK_ALLOC   YYMALLOC
 
#define YYSTACK_FREE   YYFREE
 
#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM
 
#define YYMALLOC   xmalloc
 
#define YYFREE   xfree
 
#define YYSTACK_GAP_MAXIMUM   (YYSIZEOF (union f_exp_yyalloc) - 1)
 
#define YYSTACK_BYTES(N)
 
#define YYCOPY_NEEDED   1
 
#define YYSTACK_RELOCATE(Stack_alloc, Stack)
 
#define YYCOPY(Dst, Src, Count)
 
#define YYFINAL   69
 
#define YYLAST   924
 
#define YYNTOKENS   72
 
#define YYNNTS   20
 
#define YYNRULES   113
 
#define YYNSTATES   184
 
#define YYMAXUTOK   310
 
#define YYTRANSLATE(YYX)
 
#define YY_ACCESSING_SYMBOL(State)   YY_CAST (f_exp_yysymbol_kind_t, yystos[State])
 
#define YYPACT_NINF   (-103)
 
#define yypact_value_is_default(Yyn)    ((Yyn) == YYPACT_NINF)
 
#define YYTABLE_NINF   (-1)
 
#define yytable_value_is_error(Yyn)    0
 
#define yyerrok   (yyerrstatus = 0)
 
#define yyclearin   (yychar = YYEMPTY)
 
#define YYACCEPT   goto yyacceptlab
 
#define YYABORT   goto yyabortlab
 
#define YYERROR   goto yyerrorlab
 
#define YYNOMEM   goto yyexhaustedlab
 
#define YYRECOVERING()   (!!yyerrstatus)
 
#define YYBACKUP(Token, Value)
 
#define YYERRCODE   YYUNDEF
 
#define YYDPRINTF(Args)
 
#define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
 
#define YY_STACK_PRINT(Bottom, Top)
 
#define YY_REDUCE_PRINT(Rule)
 
#define YYINITDEPTH   200
 
#define YYMAXDEPTH   10000
 
#define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
 
#define GROWBY_MIN_SIZE   64 /* Minimum amount to grow buffer by */
 
#define CHECKBUF(size)
 

Typedefs

typedef enum yytokentype yytoken_kind_t
 
typedef union f_exp_YYSTYPE f_exp_YYSTYPE
 
typedef enum f_exp_yysymbol_kind_t f_exp_yysymbol_kind_t
 
typedef signed char yytype_int8
 
typedef short yytype_int16
 
typedef unsigned char yytype_uint8
 
typedef unsigned short yytype_uint16
 
typedef yytype_uint8 yy_state_t
 
typedef int yy_state_fast_t
 

Enumerations

enum  yytokentype {
  YYEMPTY = -2 , YYEOF = 0 , YYerror = 256 , YYUNDEF = 257 ,
  INT = 258 , FLOAT = 259 , STRING_LITERAL = 260 , BOOLEAN_LITERAL = 261 ,
  NAME = 262 , TYPENAME = 263 , COMPLETE = 264 , NAME_OR_INT = 265 ,
  SIZEOF = 266 , KIND = 267 , ERROR = 268 , INT_S1_KEYWORD = 269 ,
  INT_S2_KEYWORD = 270 , INT_KEYWORD = 271 , INT_S4_KEYWORD = 272 , INT_S8_KEYWORD = 273 ,
  LOGICAL_S1_KEYWORD = 274 , LOGICAL_S2_KEYWORD = 275 , LOGICAL_KEYWORD = 276 , LOGICAL_S4_KEYWORD = 277 ,
  LOGICAL_S8_KEYWORD = 278 , REAL_KEYWORD = 279 , REAL_S4_KEYWORD = 280 , REAL_S8_KEYWORD = 281 ,
  REAL_S16_KEYWORD = 282 , COMPLEX_KEYWORD = 283 , COMPLEX_S4_KEYWORD = 284 , COMPLEX_S8_KEYWORD = 285 ,
  COMPLEX_S16_KEYWORD = 286 , BOOL_AND = 287 , BOOL_OR = 288 , BOOL_NOT = 289 ,
  SINGLE = 290 , DOUBLE = 291 , PRECISION = 292 , CHARACTER = 293 ,
  DOLLAR_VARIABLE = 294 , ASSIGN_MODIFY = 295 , UNOP_INTRINSIC = 296 , BINOP_INTRINSIC = 297 ,
  UNOP_OR_BINOP_INTRINSIC = 298 , UNOP_OR_BINOP_OR_TERNOP_INTRINSIC = 299 , ABOVE_COMMA = 300 , EQUAL = 301 ,
  NOTEQUAL = 302 , LESSTHAN = 303 , GREATERTHAN = 304 , LEQ = 305 ,
  GEQ = 306 , LSH = 307 , RSH = 308 , STARSTAR = 309 ,
  UNARY = 310
}
 
enum  f_exp_yysymbol_kind_t {
  YYSYMBOL_YYEMPTY = -2 , YYSYMBOL_YYEOF = 0 , YYSYMBOL_YYerror = 1 , YYSYMBOL_YYUNDEF = 2 ,
  YYSYMBOL_INT = 3 , YYSYMBOL_FLOAT = 4 , YYSYMBOL_STRING_LITERAL = 5 , YYSYMBOL_BOOLEAN_LITERAL = 6 ,
  YYSYMBOL_NAME = 7 , YYSYMBOL_TYPENAME = 8 , YYSYMBOL_COMPLETE = 9 , YYSYMBOL_NAME_OR_INT = 10 ,
  YYSYMBOL_SIZEOF = 11 , YYSYMBOL_KIND = 12 , YYSYMBOL_ERROR = 13 , YYSYMBOL_INT_S1_KEYWORD = 14 ,
  YYSYMBOL_INT_S2_KEYWORD = 15 , YYSYMBOL_INT_KEYWORD = 16 , YYSYMBOL_INT_S4_KEYWORD = 17 , YYSYMBOL_INT_S8_KEYWORD = 18 ,
  YYSYMBOL_LOGICAL_S1_KEYWORD = 19 , YYSYMBOL_LOGICAL_S2_KEYWORD = 20 , YYSYMBOL_LOGICAL_KEYWORD = 21 , YYSYMBOL_LOGICAL_S4_KEYWORD = 22 ,
  YYSYMBOL_LOGICAL_S8_KEYWORD = 23 , YYSYMBOL_REAL_KEYWORD = 24 , YYSYMBOL_REAL_S4_KEYWORD = 25 , YYSYMBOL_REAL_S8_KEYWORD = 26 ,
  YYSYMBOL_REAL_S16_KEYWORD = 27 , YYSYMBOL_COMPLEX_KEYWORD = 28 , YYSYMBOL_COMPLEX_S4_KEYWORD = 29 , YYSYMBOL_COMPLEX_S8_KEYWORD = 30 ,
  YYSYMBOL_COMPLEX_S16_KEYWORD = 31 , YYSYMBOL_BOOL_AND = 32 , YYSYMBOL_BOOL_OR = 33 , YYSYMBOL_BOOL_NOT = 34 ,
  YYSYMBOL_SINGLE = 35 , YYSYMBOL_DOUBLE = 36 , YYSYMBOL_PRECISION = 37 , YYSYMBOL_CHARACTER = 38 ,
  YYSYMBOL_DOLLAR_VARIABLE = 39 , YYSYMBOL_ASSIGN_MODIFY = 40 , YYSYMBOL_UNOP_INTRINSIC = 41 , YYSYMBOL_BINOP_INTRINSIC = 42 ,
  YYSYMBOL_UNOP_OR_BINOP_INTRINSIC = 43 , YYSYMBOL_UNOP_OR_BINOP_OR_TERNOP_INTRINSIC = 44 , YYSYMBOL_45_ = 45 , YYSYMBOL_ABOVE_COMMA = 46 ,
  YYSYMBOL_47_ = 47 , YYSYMBOL_48_ = 48 , YYSYMBOL_49_ = 49 , YYSYMBOL_50_ = 50 ,
  YYSYMBOL_51_ = 51 , YYSYMBOL_EQUAL = 52 , YYSYMBOL_NOTEQUAL = 53 , YYSYMBOL_LESSTHAN = 54 ,
  YYSYMBOL_GREATERTHAN = 55 , YYSYMBOL_LEQ = 56 , YYSYMBOL_GEQ = 57 , YYSYMBOL_LSH = 58 ,
  YYSYMBOL_RSH = 59 , YYSYMBOL_60_ = 60 , YYSYMBOL_61_ = 61 , YYSYMBOL_62_ = 62 ,
  YYSYMBOL_63_ = 63 , YYSYMBOL_64_ = 64 , YYSYMBOL_STARSTAR = 65 , YYSYMBOL_66_ = 66 ,
  YYSYMBOL_UNARY = 67 , YYSYMBOL_68_ = 68 , YYSYMBOL_69_ = 69 , YYSYMBOL_70_ = 70 ,
  YYSYMBOL_71_ = 71 , YYSYMBOL_YYACCEPT = 72 , YYSYMBOL_start = 73 , YYSYMBOL_type_exp = 74 ,
  YYSYMBOL_exp = 75 , YYSYMBOL_76_1 = 76 , YYSYMBOL_77_2 = 77 , YYSYMBOL_78_3 = 78 ,
  YYSYMBOL_arglist = 79 , YYSYMBOL_subrange = 80 , YYSYMBOL_complexnum = 81 , YYSYMBOL_variable = 82 ,
  YYSYMBOL_type = 83 , YYSYMBOL_ptype = 84 , YYSYMBOL_abs_decl = 85 , YYSYMBOL_direct_abs_decl = 86 ,
  YYSYMBOL_func_mod = 87 , YYSYMBOL_typebase = 88 , YYSYMBOL_nonempty_typelist = 89 , YYSYMBOL_name = 90 ,
  YYSYMBOL_name_not_typename = 91
}
 
enum  { YYENOMEM = -2 }
 

Functions

int yyparse (void)
 
static int yylex (void)
 
static void yyerror (const char *)
 
static void growbuf_by_size (int)
 
static int match_string_literal (void)
 
static void push_kind_type (LONGEST val, struct type *type)
 
static struct typeconvert_to_kind_type (struct type *basetype, int kind)
 
static void wrap_unop_intrinsic (exp_opcode opcode)
 
static void wrap_binop_intrinsic (exp_opcode opcode)
 
static void wrap_ternop_intrinsic (exp_opcode opcode)
 
template<typename T >
static void fortran_wrap2_kind (type *base_type)
 
template<typename T >
static void fortran_wrap3_kind (type *base_type)
 
static int parse_number (struct parser_state *, const char *, int, int, f_exp_YYSTYPE *)
 
void * xmalloc (YYSIZE_T)
 
void xfree (void *)
 
static const char * yysymbol_name (f_exp_yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED
 
static void yy_symbol_value_print (FILE *yyo, f_exp_yysymbol_kind_t yykind, f_exp_YYSTYPE const *const yyvaluep)
 
static void yy_symbol_print (FILE *yyo, f_exp_yysymbol_kind_t yykind, f_exp_YYSTYPE const *const yyvaluep)
 
static void yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop)
 
static void yy_reduce_print (yy_state_t *yyssp, f_exp_YYSTYPE *yyvsp, int yyrule)
 
static void yydestruct (const char *yymsg, f_exp_yysymbol_kind_t yykind, f_exp_YYSTYPE *yyvaluep)
 

Variables

static struct parser_statepstate = NULL
 
static int paren_depth
 
static struct type_stack * type_stack
 
int yydebug
 
f_exp_YYSTYPE yylval
 
static const yytype_int8 yytranslate []
 
static const yytype_int16 yyrline []
 
static const char *const yytname []
 
static const yytype_int16 yypact []
 
static const yytype_int8 yydefact []
 
static const yytype_int8 yypgoto []
 
static const yytype_uint8 yydefgoto []
 
static const yytype_uint8 yytable []
 
static const yytype_int16 yycheck []
 
static const yytype_int8 yystos []
 
static const yytype_int8 yyr1 []
 
static const yytype_int8 yyr2 []
 
int yychar
 
int yynerrs
 
static const struct f_token fortran_operators []
 
static const struct f77_boolean_val boolean_values []
 
static const struct f_token f_intrinsics []
 
static const f_token f_keywords []
 
static char * tempbuf
 
static int tempbufsize
 
static int tempbufindex
 
static bool saw_name_at_eof
 
static bool last_was_structop
 

Macro Definition Documentation

◆ ABOVE_COMMA

#define ABOVE_COMMA   300

Definition at line 276 of file f-exp.c.

◆ ASSIGN_MODIFY

#define ASSIGN_MODIFY   295

Definition at line 271 of file f-exp.c.

◆ BINOP_INTRINSIC

#define BINOP_INTRINSIC   297

Definition at line 273 of file f-exp.c.

◆ BOOL_AND

#define BOOL_AND   287

Definition at line 263 of file f-exp.c.

◆ BOOL_NOT

#define BOOL_NOT   289

Definition at line 265 of file f-exp.c.

◆ BOOL_OR

#define BOOL_OR   288

Definition at line 264 of file f-exp.c.

◆ BOOLEAN_LITERAL

#define BOOLEAN_LITERAL   261

Definition at line 237 of file f-exp.c.

Referenced by yylex().

◆ CHARACTER

#define CHARACTER   293

Definition at line 269 of file f-exp.c.

◆ CHECKBUF

#define CHECKBUF ( size)
Value:
do { \
{ \
growbuf_by_size (size); \
} \
} while (0);
static int tempbufsize
Definition f-exp.c:3222
static int tempbufindex
Definition f-exp.c:3223
size_t size
Definition go32-nat.c:239

Definition at line 3227 of file f-exp.c.

Referenced by match_string_literal().

◆ COMPLETE

#define COMPLETE   264

Definition at line 240 of file f-exp.c.

Referenced by yylex().

◆ COMPLEX_KEYWORD

#define COMPLEX_KEYWORD   283

Definition at line 259 of file f-exp.c.

◆ COMPLEX_S16_KEYWORD

#define COMPLEX_S16_KEYWORD   286

Definition at line 262 of file f-exp.c.

◆ COMPLEX_S4_KEYWORD

#define COMPLEX_S4_KEYWORD   284

Definition at line 260 of file f-exp.c.

◆ COMPLEX_S8_KEYWORD

#define COMPLEX_S8_KEYWORD   285

Definition at line 261 of file f-exp.c.

◆ DOLLAR_VARIABLE

#define DOLLAR_VARIABLE   294

Definition at line 270 of file f-exp.c.

Referenced by yylex().

◆ DOUBLE

#define DOUBLE   291

Definition at line 267 of file f-exp.c.

◆ EQUAL

#define EQUAL   301

Definition at line 277 of file f-exp.c.

◆ ERROR

#define ERROR   268

Definition at line 244 of file f-exp.c.

Referenced by parse_number(), and yylex().

◆ f_exp_YYSTYPE_IS_DECLARED

#define f_exp_YYSTYPE_IS_DECLARED   1

Definition at line 321 of file f-exp.c.

◆ f_exp_YYSTYPE_IS_TRIVIAL

#define f_exp_YYSTYPE_IS_TRIVIAL   1

Definition at line 320 of file f-exp.c.

◆ FLOAT

#define FLOAT   259

Definition at line 235 of file f-exp.c.

Referenced by parse_number().

◆ GDB_YY_REMAP_PREFIX

#define GDB_YY_REMAP_PREFIX   f_

Definition at line 90 of file f-exp.c.

◆ GEQ

#define GEQ   306

Definition at line 282 of file f-exp.c.

◆ GREATERTHAN

#define GREATERTHAN   304

Definition at line 280 of file f-exp.c.

◆ GROWBY_MIN_SIZE

#define GROWBY_MIN_SIZE   64 /* Minimum amount to grow buffer by */

Definition at line 3225 of file f-exp.c.

Referenced by growbuf_by_size().

◆ INT

#define INT   258

Definition at line 234 of file f-exp.c.

Referenced by parse_number(), and yylex().

◆ INT_KEYWORD

#define INT_KEYWORD   271

Definition at line 247 of file f-exp.c.

◆ INT_S1_KEYWORD

#define INT_S1_KEYWORD   269

Definition at line 245 of file f-exp.c.

◆ INT_S2_KEYWORD

#define INT_S2_KEYWORD   270

Definition at line 246 of file f-exp.c.

◆ INT_S4_KEYWORD

#define INT_S4_KEYWORD   272

Definition at line 248 of file f-exp.c.

◆ INT_S8_KEYWORD

#define INT_S8_KEYWORD   273

Definition at line 249 of file f-exp.c.

◆ KIND

#define KIND   267

Definition at line 243 of file f-exp.c.

◆ LEQ

#define LEQ   305

Definition at line 281 of file f-exp.c.

◆ LESSTHAN

#define LESSTHAN   303

Definition at line 279 of file f-exp.c.

◆ LOGICAL_KEYWORD

#define LOGICAL_KEYWORD   276

Definition at line 252 of file f-exp.c.

◆ LOGICAL_S1_KEYWORD

#define LOGICAL_S1_KEYWORD   274

Definition at line 250 of file f-exp.c.

◆ LOGICAL_S2_KEYWORD

#define LOGICAL_S2_KEYWORD   275

Definition at line 251 of file f-exp.c.

◆ LOGICAL_S4_KEYWORD

#define LOGICAL_S4_KEYWORD   277

Definition at line 253 of file f-exp.c.

◆ LOGICAL_S8_KEYWORD

#define LOGICAL_S8_KEYWORD   278

Definition at line 254 of file f-exp.c.

◆ LSH

#define LSH   307

Definition at line 283 of file f-exp.c.

◆ NAME

#define NAME   262

Definition at line 238 of file f-exp.c.

Referenced by yylex().

◆ NAME_OR_INT

#define NAME_OR_INT   265

Definition at line 241 of file f-exp.c.

Referenced by yylex().

◆ NOTEQUAL

#define NOTEQUAL   302

Definition at line 278 of file f-exp.c.

◆ parse_f_type

#define parse_f_type ( ps)    builtin_f_type (ps->gdbarch ())

◆ parse_type

#define parse_type ( ps)    builtin_type (ps->gdbarch ())

Definition at line 85 of file f-exp.c.

Referenced by parse_number().

◆ PRECISION

#define PRECISION   292

Definition at line 268 of file f-exp.c.

◆ REAL_KEYWORD

#define REAL_KEYWORD   279

Definition at line 255 of file f-exp.c.

◆ REAL_S16_KEYWORD

#define REAL_S16_KEYWORD   282

Definition at line 258 of file f-exp.c.

◆ REAL_S4_KEYWORD

#define REAL_S4_KEYWORD   280

Definition at line 256 of file f-exp.c.

◆ REAL_S8_KEYWORD

#define REAL_S8_KEYWORD   281

Definition at line 257 of file f-exp.c.

◆ RSH

#define RSH   308

Definition at line 284 of file f-exp.c.

◆ SINGLE

#define SINGLE   290

Definition at line 266 of file f-exp.c.

Referenced by print_converted_chars_to_obstack().

◆ SIZEOF

#define SIZEOF   266

Definition at line 242 of file f-exp.c.

◆ STARSTAR

#define STARSTAR   309

Definition at line 285 of file f-exp.c.

◆ STRING_LITERAL

#define STRING_LITERAL   260

Definition at line 236 of file f-exp.c.

Referenced by match_string_literal().

◆ TYPENAME

#define TYPENAME   263

Definition at line 239 of file f-exp.c.

Referenced by yylex().

◆ UNARY

#define UNARY   310

Definition at line 286 of file f-exp.c.

◆ UNOP_INTRINSIC

#define UNOP_INTRINSIC   296

Definition at line 272 of file f-exp.c.

◆ UNOP_OR_BINOP_INTRINSIC

#define UNOP_OR_BINOP_INTRINSIC   298

Definition at line 274 of file f-exp.c.

◆ UNOP_OR_BINOP_OR_TERNOP_INTRINSIC

#define UNOP_OR_BINOP_OR_TERNOP_INTRINSIC   299

Definition at line 275 of file f-exp.c.

◆ YY_

#define YY_ ( Msgid)    Msgid

Definition at line 565 of file f-exp.c.

Referenced by yyparse().

◆ YY_ACCESSING_SYMBOL

#define YY_ACCESSING_SYMBOL ( State)    YY_CAST (f_exp_yysymbol_kind_t, yystos[State])

Accessing symbol of state STATE.

Definition at line 842 of file f-exp.c.

Referenced by yy_reduce_print(), and yyparse().

◆ YY_ASSERT

#define YY_ASSERT ( E)    ((void) (0 && (E)))

Definition at line 631 of file f-exp.c.

Referenced by yyparse().

◆ YY_ATTRIBUTE_PURE

#define YY_ATTRIBUTE_PURE

Definition at line 574 of file f-exp.c.

◆ YY_ATTRIBUTE_UNUSED

#define YY_ATTRIBUTE_UNUSED

Definition at line 582 of file f-exp.c.

◆ YY_CAST

#define YY_CAST ( Type,
Val )   ((Type) (Val))

Definition at line 139 of file f-exp.c.

Referenced by yyparse().

◆ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN

#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN

Definition at line 611 of file f-exp.c.

Referenced by yy_symbol_value_print(), yydestruct(), and yyparse().

◆ YY_IGNORE_MAYBE_UNINITIALIZED_END

#define YY_IGNORE_MAYBE_UNINITIALIZED_END

Definition at line 612 of file f-exp.c.

Referenced by yy_symbol_value_print(), yydestruct(), and yyparse().

◆ YY_IGNORE_USELESS_CAST_BEGIN

#define YY_IGNORE_USELESS_CAST_BEGIN

Definition at line 626 of file f-exp.c.

Referenced by yyparse().

◆ YY_IGNORE_USELESS_CAST_END

#define YY_IGNORE_USELESS_CAST_END

Definition at line 627 of file f-exp.c.

Referenced by yyparse().

◆ YY_INITIAL_VALUE

#define YY_INITIAL_VALUE ( Value)    Value

Definition at line 608 of file f-exp.c.

◆ YY_NULLPTRPTR

#define YY_NULLPTRPTR   ((void*)0)

Definition at line 151 of file f-exp.c.

◆ YY_REDUCE_PRINT

#define YY_REDUCE_PRINT ( Rule)
Value:
do { \
if (yydebug) \
yy_reduce_print (yyssp, yyvsp, Rule); \
} while (0)
int yydebug
Definition f-exp.c:1365
#define yyvsp
Definition yy-remap.h:87
#define yyssp
Definition yy-remap.h:84

Definition at line 1357 of file f-exp.c.

Referenced by yyparse().

◆ YY_REINTERPRET_CAST

#define YY_REINTERPRET_CAST ( Type,
Val )   ((Type) (Val))

Definition at line 140 of file f-exp.c.

◆ YY_STACK_PRINT

#define YY_STACK_PRINT ( Bottom,
Top )
Value:
do { \
if (yydebug) \
yy_stack_print ((Bottom), (Top)); \
} while (0)

Definition at line 1326 of file f-exp.c.

Referenced by yyparse().

◆ YY_SYMBOL_PRINT

#define YY_SYMBOL_PRINT ( Title,
Kind,
Value,
Location )
Value:
do { \
if (yydebug) \
{ \
YYFPRINTF (stderr, "%s ", Title); \
yy_symbol_print (stderr, \
Kind, Value); \
YYFPRINTF (stderr, "\n"); \
} \
} while (0)

Definition at line 1264 of file f-exp.c.

Referenced by yydestruct(), and yyparse().

◆ YY_USE

#define YY_USE ( E)    ((void) (E))

Definition at line 588 of file f-exp.c.

Referenced by yy_symbol_value_print(), and yydestruct().

◆ YYABORT

#define YYABORT   goto yyabortlab

Definition at line 1218 of file f-exp.c.

Referenced by yyparse().

◆ YYACCEPT

#define YYACCEPT   goto yyacceptlab

Definition at line 1217 of file f-exp.c.

Referenced by yyparse().

◆ YYBACKUP

#define YYBACKUP ( Token,
Value )
Value:
do \
if (yychar == YYEMPTY) \
{ \
yychar = (Token); \
yylval = (Value); \
YYPOPSTACK (yylen); \
yystate = *yyssp; \
goto yybackup; \
} \
else \
{ \
yyerror (YY_("syntax error: cannot back up")); \
} \
while (0)
#define YY_(Msgid)
Definition f-exp.c:565
f_exp_YYSTYPE yylval
Definition f-exp.c:1418
int yychar
Definition f-exp.c:1415
#define YYEMPTY
Definition f-exp.c:230
#define YYERROR
Definition f-exp.c:1219
#define yylen
Definition yy-remap.h:74
#define yystate
Definition yy-remap.h:63

Definition at line 1225 of file f-exp.c.

◆ YYBISON

#define YYBISON   30802

Definition at line 49 of file f-exp.c.

◆ YYBISON_VERSION

#define YYBISON_VERSION   "3.8.2"

Definition at line 52 of file f-exp.c.

◆ yyclearin

#define yyclearin   (yychar = YYEMPTY)

Definition at line 1215 of file f-exp.c.

◆ YYCOPY

#define YYCOPY ( Dst,
Src,
Count )
Value:
do \
{ \
YYPTRDIFF_T yyi; \
for (yyi = 0; yyi < (Count); yyi++) \
(Dst)[yyi] = (Src)[yyi]; \
} \
while (0)
#define YYPTRDIFF_T
Definition f-exp.c:524

Definition at line 747 of file f-exp.c.

◆ YYCOPY_NEEDED

#define YYCOPY_NEEDED   1

Definition at line 719 of file f-exp.c.

◆ YYDPRINTF

#define YYDPRINTF ( Args)
Value:
do { \
if (yydebug) \
YYFPRINTF Args; \
} while (0)
#define YYFPRINTF
Definition yy-remap.h:97

Definition at line 1255 of file f-exp.c.

Referenced by yyparse().

◆ YYEMPTY

#define YYEMPTY   -2

Definition at line 230 of file f-exp.c.

Referenced by yyparse().

◆ YYEOF

#define YYEOF   0

Definition at line 231 of file f-exp.c.

Referenced by yyparse().

◆ YYERRCODE

#define YYERRCODE   YYUNDEF

Definition at line 1244 of file f-exp.c.

◆ yyerrok

#define yyerrok   (yyerrstatus = 0)

Definition at line 1214 of file f-exp.c.

◆ YYerror

#define YYerror   256

Definition at line 232 of file f-exp.c.

Referenced by yyparse().

◆ YYERROR

#define YYERROR   goto yyerrorlab

Definition at line 1219 of file f-exp.c.

Referenced by yyparse().

◆ YYFINAL

#define YYFINAL   69

Definition at line 760 of file f-exp.c.

Referenced by yyparse().

◆ YYFREE

#define YYFREE   xfree

Definition at line 691 of file f-exp.c.

◆ YYINITDEPTH

#define YYINITDEPTH   200

Definition at line 1376 of file f-exp.c.

Referenced by yyparse().

◆ YYLAST

#define YYLAST   924

Definition at line 762 of file f-exp.c.

Referenced by yyparse().

◆ YYMALLOC

#define YYMALLOC   xmalloc

Definition at line 685 of file f-exp.c.

◆ YYMAXDEPTH

#define YYMAXDEPTH   10000

Definition at line 1387 of file f-exp.c.

Referenced by yyparse().

◆ YYMAXUTOK

#define YYMAXUTOK   310

Definition at line 774 of file f-exp.c.

◆ YYNNTS

#define YYNNTS   20

Definition at line 767 of file f-exp.c.

◆ YYNOMEM

#define YYNOMEM   goto yyexhaustedlab

Definition at line 1220 of file f-exp.c.

Referenced by yyparse().

◆ YYNRULES

#define YYNRULES   113

Definition at line 769 of file f-exp.c.

◆ YYNSTATES

#define YYNSTATES   184

Definition at line 771 of file f-exp.c.

Referenced by yyparse().

◆ YYNTOKENS

#define YYNTOKENS   72

Definition at line 765 of file f-exp.c.

Referenced by yy_symbol_print(), and yyparse().

◆ YYPACT_NINF

#define YYPACT_NINF   (-103)

Definition at line 880 of file f-exp.c.

◆ yypact_value_is_default

#define yypact_value_is_default ( Yyn)     ((Yyn) == YYPACT_NINF)

Definition at line 882 of file f-exp.c.

Referenced by yyparse().

◆ YYPOPSTACK

#define YYPOPSTACK ( N)    (yyvsp -= (N), yyssp -= (N))

◆ YYPTRDIFF_MAXIMUM

#define YYPTRDIFF_MAXIMUM   LONG_MAX

Definition at line 525 of file f-exp.c.

◆ YYPTRDIFF_T

#define YYPTRDIFF_T   long

Definition at line 524 of file f-exp.c.

Referenced by yyparse().

◆ YYPULL

#define YYPULL   1

Definition at line 64 of file f-exp.c.

◆ YYPURE

#define YYPURE   0

Definition at line 58 of file f-exp.c.

◆ YYPUSH

#define YYPUSH   0

Definition at line 61 of file f-exp.c.

◆ YYRECOVERING

#define YYRECOVERING ( )    (!!yyerrstatus)

Definition at line 1223 of file f-exp.c.

◆ YYSIZE_MAXIMUM

#define YYSIZE_MAXIMUM
Value:
: YY_CAST (YYSIZE_T, -1)))
#define YYPTRDIFF_MAXIMUM
Definition f-exp.c:525
#define YY_CAST(Type, Val)
Definition f-exp.c:139
#define YYSIZE_T
Definition f-exp.c:538

Definition at line 542 of file f-exp.c.

◆ YYSIZE_T

#define YYSIZE_T   unsigned

Definition at line 538 of file f-exp.c.

Referenced by yyparse().

◆ YYSIZEOF

#define YYSIZEOF ( X)    YY_CAST (YYPTRDIFF_T, sizeof (X))

Definition at line 548 of file f-exp.c.

Referenced by yyparse().

◆ YYSKELETON_NAME

#define YYSKELETON_NAME   "yacc.c"

Definition at line 55 of file f-exp.c.

◆ YYSTACK_ALLOC

#define YYSTACK_ALLOC   YYMALLOC

Definition at line 671 of file f-exp.c.

Referenced by yyparse().

◆ YYSTACK_ALLOC_MAXIMUM

#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM

Definition at line 674 of file f-exp.c.

◆ YYSTACK_BYTES

#define YYSTACK_BYTES ( N)
Value:
yytype_uint8 yy_state_t
Definition ada-exp.c:871
#define YYSIZEOF(X)
Definition f-exp.c:548
#define YYSTACK_GAP_MAXIMUM
Definition f-exp.c:711

Definition at line 715 of file f-exp.c.

Referenced by yyparse().

◆ YYSTACK_FREE

#define YYSTACK_FREE   YYFREE

Definition at line 672 of file f-exp.c.

Referenced by yyparse().

◆ YYSTACK_GAP_MAXIMUM

#define YYSTACK_GAP_MAXIMUM   (YYSIZEOF (union f_exp_yyalloc) - 1)

Definition at line 711 of file f-exp.c.

◆ YYSTACK_RELOCATE

#define YYSTACK_RELOCATE ( Stack_alloc,
Stack )
Value:
do \
{ \
YYPTRDIFF_T yynewbytes; \
YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
Stack = &yyptr->Stack_alloc; \
yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
yyptr += yynewbytes / YYSIZEOF (*yyptr); \
} \
while (0)
#define yystacksize
Definition yy-remap.h:85

Definition at line 726 of file f-exp.c.

Referenced by yyparse().

◆ YYTABLE_NINF

#define YYTABLE_NINF   (-1)

Definition at line 885 of file f-exp.c.

◆ yytable_value_is_error

#define yytable_value_is_error ( Yyn)     0

Definition at line 887 of file f-exp.c.

Referenced by yyparse().

◆ YYTOKENTYPE

#define YYTOKENTYPE

Definition at line 166 of file f-exp.c.

◆ YYTRANSLATE

#define YYTRANSLATE ( YYX)
Value:
(0 <= (YYX) && (YYX) <= YYMAXUTOK \
f_exp_yysymbol_kind_t
Definition f-exp.c:334
@ YYSYMBOL_YYUNDEF
Definition f-exp.c:338
static const yytype_int8 yytranslate[]
Definition f-exp.c:786
#define YYMAXUTOK
Definition f-exp.c:774

Definition at line 779 of file f-exp.c.

Referenced by yyparse().

◆ YYUNDEF

#define YYUNDEF   257

Definition at line 233 of file f-exp.c.

Referenced by yyparse().

Typedef Documentation

◆ f_exp_YYSTYPE

typedef union f_exp_YYSTYPE f_exp_YYSTYPE

Definition at line 319 of file f-exp.c.

◆ f_exp_yysymbol_kind_t

Definition at line 429 of file f-exp.c.

◆ yy_state_fast_t

typedef int yy_state_fast_t

Definition at line 555 of file f-exp.c.

◆ yy_state_t

Definition at line 552 of file f-exp.c.

◆ yytoken_kind_t

Definition at line 227 of file f-exp.c.

◆ yytype_int16

typedef short yytype_int16

Definition at line 476 of file f-exp.c.

◆ yytype_int8

typedef signed char yytype_int8

Definition at line 468 of file f-exp.c.

◆ yytype_uint16

typedef unsigned short yytype_uint16

Definition at line 508 of file f-exp.c.

◆ yytype_uint8

typedef unsigned char yytype_uint8

Definition at line 497 of file f-exp.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
YYENOMEM 

Definition at line 1212 of file f-exp.c.

◆ f_exp_yysymbol_kind_t

Enumerator
YYSYMBOL_YYEMPTY 
YYSYMBOL_YYEOF 
YYSYMBOL_YYerror 
YYSYMBOL_YYUNDEF 
YYSYMBOL_INT 
YYSYMBOL_FLOAT 
YYSYMBOL_STRING_LITERAL 
YYSYMBOL_BOOLEAN_LITERAL 
YYSYMBOL_NAME 
YYSYMBOL_TYPENAME 
YYSYMBOL_COMPLETE 
YYSYMBOL_NAME_OR_INT 
YYSYMBOL_SIZEOF 
YYSYMBOL_KIND 
YYSYMBOL_ERROR 
YYSYMBOL_INT_S1_KEYWORD 
YYSYMBOL_INT_S2_KEYWORD 
YYSYMBOL_INT_KEYWORD 
YYSYMBOL_INT_S4_KEYWORD 
YYSYMBOL_INT_S8_KEYWORD 
YYSYMBOL_LOGICAL_S1_KEYWORD 
YYSYMBOL_LOGICAL_S2_KEYWORD 
YYSYMBOL_LOGICAL_KEYWORD 
YYSYMBOL_LOGICAL_S4_KEYWORD 
YYSYMBOL_LOGICAL_S8_KEYWORD 
YYSYMBOL_REAL_KEYWORD 
YYSYMBOL_REAL_S4_KEYWORD 
YYSYMBOL_REAL_S8_KEYWORD 
YYSYMBOL_REAL_S16_KEYWORD 
YYSYMBOL_COMPLEX_KEYWORD 
YYSYMBOL_COMPLEX_S4_KEYWORD 
YYSYMBOL_COMPLEX_S8_KEYWORD 
YYSYMBOL_COMPLEX_S16_KEYWORD 
YYSYMBOL_BOOL_AND 
YYSYMBOL_BOOL_OR 
YYSYMBOL_BOOL_NOT 
YYSYMBOL_SINGLE 
YYSYMBOL_DOUBLE 
YYSYMBOL_PRECISION 
YYSYMBOL_CHARACTER 
YYSYMBOL_DOLLAR_VARIABLE 
YYSYMBOL_ASSIGN_MODIFY 
YYSYMBOL_UNOP_INTRINSIC 
YYSYMBOL_BINOP_INTRINSIC 
YYSYMBOL_UNOP_OR_BINOP_INTRINSIC 
YYSYMBOL_UNOP_OR_BINOP_OR_TERNOP_INTRINSIC 
YYSYMBOL_45_ 
YYSYMBOL_ABOVE_COMMA 
YYSYMBOL_47_ 
YYSYMBOL_48_ 
YYSYMBOL_49_ 
YYSYMBOL_50_ 
YYSYMBOL_51_ 
YYSYMBOL_EQUAL 
YYSYMBOL_NOTEQUAL 
YYSYMBOL_LESSTHAN 
YYSYMBOL_GREATERTHAN 
YYSYMBOL_LEQ 
YYSYMBOL_GEQ 
YYSYMBOL_LSH 
YYSYMBOL_RSH 
YYSYMBOL_60_ 
YYSYMBOL_61_ 
YYSYMBOL_62_ 
YYSYMBOL_63_ 
YYSYMBOL_64_ 
YYSYMBOL_STARSTAR 
YYSYMBOL_66_ 
YYSYMBOL_UNARY 
YYSYMBOL_68_ 
YYSYMBOL_69_ 
YYSYMBOL_70_ 
YYSYMBOL_71_ 
YYSYMBOL_YYACCEPT 
YYSYMBOL_start 
YYSYMBOL_type_exp 
YYSYMBOL_exp 
YYSYMBOL_76_1 
YYSYMBOL_77_2 
YYSYMBOL_78_3 
YYSYMBOL_arglist 
YYSYMBOL_subrange 
YYSYMBOL_complexnum 
YYSYMBOL_variable 
YYSYMBOL_type 
YYSYMBOL_ptype 
YYSYMBOL_abs_decl 
YYSYMBOL_direct_abs_decl 
YYSYMBOL_func_mod 
YYSYMBOL_typebase 
YYSYMBOL_nonempty_typelist 
YYSYMBOL_name 
YYSYMBOL_name_not_typename 

Definition at line 333 of file f-exp.c.

◆ yytokentype

Enumerator
YYEMPTY 
YYEOF 
YYerror 
YYUNDEF 
INT 
FLOAT 
STRING_LITERAL 
BOOLEAN_LITERAL 
NAME 
TYPENAME 
COMPLETE 
NAME_OR_INT 
SIZEOF 
KIND 
ERROR 
INT_S1_KEYWORD 
INT_S2_KEYWORD 
INT_KEYWORD 
INT_S4_KEYWORD 
INT_S8_KEYWORD 
LOGICAL_S1_KEYWORD 
LOGICAL_S2_KEYWORD 
LOGICAL_KEYWORD 
LOGICAL_S4_KEYWORD 
LOGICAL_S8_KEYWORD 
REAL_KEYWORD 
REAL_S4_KEYWORD 
REAL_S8_KEYWORD 
REAL_S16_KEYWORD 
COMPLEX_KEYWORD 
COMPLEX_S4_KEYWORD 
COMPLEX_S8_KEYWORD 
COMPLEX_S16_KEYWORD 
BOOL_AND 
BOOL_OR 
BOOL_NOT 
SINGLE 
DOUBLE 
PRECISION 
CHARACTER 
DOLLAR_VARIABLE 
ASSIGN_MODIFY 
UNOP_INTRINSIC 
BINOP_INTRINSIC 
UNOP_OR_BINOP_INTRINSIC 
UNOP_OR_BINOP_OR_TERNOP_INTRINSIC 
ABOVE_COMMA 
EQUAL 
NOTEQUAL 
LESSTHAN 
GREATERTHAN 
LEQ 
GEQ 
LSH 
RSH 
STARSTAR 
UNARY 

Definition at line 167 of file f-exp.c.

Function Documentation

◆ convert_to_kind_type()

static struct type * convert_to_kind_type ( struct type * basetype,
int kind )
static

Definition at line 3052 of file f-exp.c.

References parse_f_type, pstate, and TYPE_SAFE_NAME.

Referenced by fortran_wrap2_kind(), fortran_wrap3_kind(), wrap_ternop_intrinsic(), and yyparse().

◆ fortran_wrap2_kind()

template<typename T >
static void fortran_wrap2_kind ( type * base_type)
static

◆ fortran_wrap3_kind()

template<typename T >
static void fortran_wrap3_kind ( type * base_type)
static

◆ growbuf_by_size()

static void growbuf_by_size ( int count)
static

Definition at line 3240 of file f-exp.c.

References GROWBY_MIN_SIZE, tempbuf, tempbufsize, xmalloc(), and xrealloc().

◆ match_string_literal()

static int match_string_literal ( void )
static

◆ parse_number()

static int parse_number ( struct parser_state * par_state,
const char * p,
int len,
int parsed_float,
f_exp_YYSTYPE * putithere )
static

◆ push_kind_type()

static void push_kind_type ( LONGEST val,
struct type * type )
static

Definition at line 3025 of file f-exp.c.

References type::is_unsigned(), type_stack::push(), tp_kind, and f_exp_YYSTYPE::val.

Referenced by yyparse().

◆ wrap_binop_intrinsic()

static void wrap_binop_intrinsic ( exp_opcode opcode)
static

Definition at line 2747 of file f-exp.c.

References code, parse_f_type, parser_state::pop(), pstate, parser_state::push_new(), and parser_state::wrap2().

Referenced by yyparse().

◆ wrap_ternop_intrinsic()

static void wrap_ternop_intrinsic ( exp_opcode opcode)
static

◆ wrap_unop_intrinsic()

static void wrap_unop_intrinsic ( exp_opcode opcode)
static

Definition at line 2700 of file f-exp.c.

References code, parser_state::pop(), pstate, parser_state::push_new(), and parser_state::wrap().

Referenced by yyparse().

◆ xfree()

void xfree ( void * )

Referenced by parse_number(), and yyparse().

◆ xmalloc()

void * xmalloc ( YYSIZE_T )

Referenced by growbuf_by_size(), and yyparse().

◆ yy_reduce_print()

static void yy_reduce_print ( yy_state_t * yyssp,
f_exp_YYSTYPE * yyvsp,
int yyrule )
static

Definition at line 1338 of file f-exp.c.

References YY_ACCESSING_SYMBOL, yy_symbol_print(), YYFPRINTF, yyr2, yyrline, yyrule, yyssp, and yyvsp.

◆ yy_stack_print()

static void yy_stack_print ( yy_state_t * yybottom,
yy_state_t * yytop )
static

Definition at line 1315 of file f-exp.c.

References YYFPRINTF.

◆ yy_symbol_print()

static void yy_symbol_print ( FILE * yyo,
f_exp_yysymbol_kind_t yykind,
f_exp_YYSTYPE const *const yyvaluep )
static

Definition at line 1299 of file f-exp.c.

References yy_symbol_value_print(), YYFPRINTF, YYNTOKENS, and yysymbol_name().

Referenced by yy_reduce_print().

◆ yy_symbol_value_print()

static void yy_symbol_value_print ( FILE * yyo,
f_exp_yysymbol_kind_t yykind,
f_exp_YYSTYPE const *const yyvaluep )
static

Definition at line 1281 of file f-exp.c.

References YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN, YY_IGNORE_MAYBE_UNINITIALIZED_END, and YY_USE.

Referenced by yy_symbol_print().

◆ yydestruct()

static void yydestruct ( const char * yymsg,
f_exp_yysymbol_kind_t yykind,
f_exp_YYSTYPE * yyvaluep )
static

◆ yyerror()

static void yyerror ( const char * msg)
static

Definition at line 3624 of file f-exp.c.

References parser_state::lexptr, parser_state::prev_lexptr, and pstate.

◆ yylex()

static int yylex ( void )
static

◆ yyparse()

int yyparse ( void )

Definition at line 1430 of file f-exp.c.

References parser_state::arglist_len, check_typedef(), convert_to_kind_type(), copy_name(), create_array_type(), create_static_range_type(), parser_state::end_arglist(), lookup_function_type(), lookup_lvalue_reference_type(), lookup_pointer_type(), parser_state::mark_struct_expression(), name, parse_f_type, parse_number(), parser_state::pop(), type_stack::pop(), type_stack::pop_int(), parser_state::pop_vector(), pstate, stoken::ptr, type_stack::push(), parser_state::push(), parser_state::push_dollar(), push_kind_type(), parser_state::push_new(), parser_state::push_symbol(), RANGE_HAS_STRIDE, RANGE_HIGH_BOUND_DEFAULT, RANGE_LOW_BOUND_DEFAULT, RANGE_STANDARD, parser_state::start_arglist(), tp_array, tp_end, tp_function, tp_kind, tp_pointer, tp_reference, f_exp_YYSTYPE::type, f_exp_YYSTYPE::typed_val, f_exp_YYSTYPE::val, parser_state::wrap(), parser_state::wrap2(), wrap_binop_intrinsic(), wrap_ternop_intrinsic(), wrap_unop_intrinsic(), xfree(), xmalloc(), xrealloc(), YY_, YY_ACCESSING_SYMBOL, YY_ASSERT, YY_CAST, YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN, YY_IGNORE_MAYBE_UNINITIALIZED_END, YY_IGNORE_USELESS_CAST_BEGIN, YY_IGNORE_USELESS_CAST_END, YY_REDUCE_PRINT, YY_STACK_PRINT, YY_SYMBOL_PRINT, YYABORT, YYACCEPT, yychar, yycheck, yydefact, yydefgoto, yydestruct(), YYDPRINTF, YYEMPTY, YYEOF, YYerror, YYERROR, yyerror, YYFINAL, YYINITDEPTH, YYLAST, yylen, yylex(), yylhs, yylloc, yylval, YYMAXDEPTH, yynerrs, YYNOMEM, YYNSTATES, YYNTOKENS, yypact, yypact_value_is_default, yypgoto, YYPOPSTACK, YYPTRDIFF_T, yyr1, yyr2, YYSIZE_T, YYSIZEOF, yyss, f_exp_yyalloc::yyss_alloc, yyssp, YYSTACK_ALLOC, YYSTACK_BYTES, YYSTACK_FREE, YYSTACK_RELOCATE, yystacksize, yystate, YYSYMBOL_YYEMPTY, YYSYMBOL_YYEOF, YYSYMBOL_YYerror, yytable, yytable_value_is_error, YYTRANSLATE, YYUNDEF, yyval, yyvs, f_exp_yyalloc::yyvs_alloc, and yyvsp.

◆ yysymbol_name()

static const char * yysymbol_name ( f_exp_yysymbol_kind_t yysymbol)
static

Definition at line 874 of file f-exp.c.

References yytname.

Referenced by yy_symbol_print().

Variable Documentation

◆ boolean_values

const struct f77_boolean_val boolean_values[]
static
Initial value:
=
{
{ ".true.", 1 },
{ ".false.", 0 }
}

Definition at line 3162 of file f-exp.c.

Referenced by yylex().

◆ f_intrinsics

const struct f_token f_intrinsics[]
static
Initial value:
=
{
{ "kind", KIND, OP_NULL, false },
{ "abs", UNOP_INTRINSIC, UNOP_ABS, false },
{ "mod", BINOP_INTRINSIC, BINOP_MOD, false },
{ "floor", UNOP_OR_BINOP_INTRINSIC, FORTRAN_FLOOR, false },
{ "ceiling", UNOP_OR_BINOP_INTRINSIC, FORTRAN_CEILING, false },
{ "modulo", BINOP_INTRINSIC, BINOP_FORTRAN_MODULO, false },
{ "cmplx", UNOP_OR_BINOP_OR_TERNOP_INTRINSIC, FORTRAN_CMPLX, false },
{ "lbound", UNOP_OR_BINOP_OR_TERNOP_INTRINSIC, FORTRAN_LBOUND, false },
{ "ubound", UNOP_OR_BINOP_OR_TERNOP_INTRINSIC, FORTRAN_UBOUND, false },
{ "allocated", UNOP_INTRINSIC, UNOP_FORTRAN_ALLOCATED, false },
{ "associated", UNOP_OR_BINOP_INTRINSIC, FORTRAN_ASSOCIATED, false },
{ "rank", UNOP_INTRINSIC, UNOP_FORTRAN_RANK, false },
{ "size", UNOP_OR_BINOP_OR_TERNOP_INTRINSIC, FORTRAN_ARRAY_SIZE, false },
{ "shape", UNOP_INTRINSIC, UNOP_FORTRAN_SHAPE, false },
{ "loc", UNOP_INTRINSIC, UNOP_FORTRAN_LOC, false },
{ "sizeof", SIZEOF, OP_NULL, false },
}
#define BINOP_INTRINSIC
Definition f-exp.c:273
#define SIZEOF
Definition f-exp.c:242
#define KIND
Definition f-exp.c:243
#define UNOP_OR_BINOP_OR_TERNOP_INTRINSIC
Definition f-exp.c:275
#define UNOP_INTRINSIC
Definition f-exp.c:272
#define UNOP_OR_BINOP_INTRINSIC
Definition f-exp.c:274

Definition at line 3168 of file f-exp.c.

Referenced by yylex().

◆ f_keywords

const f_token f_keywords[]
static
Initial value:
=
{
{ "character", CHARACTER, OP_NULL, true },
{ "complex", COMPLEX_KEYWORD, OP_NULL, true },
{ "complex_4", COMPLEX_S4_KEYWORD, OP_NULL, true },
{ "complex_8", COMPLEX_S8_KEYWORD, OP_NULL, true },
{ "complex_16", COMPLEX_S16_KEYWORD, OP_NULL, true },
{ "integer_1", INT_S1_KEYWORD, OP_NULL, true },
{ "integer_2", INT_S2_KEYWORD, OP_NULL, true },
{ "integer_4", INT_S4_KEYWORD, OP_NULL, true },
{ "integer", INT_KEYWORD, OP_NULL, true },
{ "integer_8", INT_S8_KEYWORD, OP_NULL, true },
{ "logical_1", LOGICAL_S1_KEYWORD, OP_NULL, true },
{ "logical_2", LOGICAL_S2_KEYWORD, OP_NULL, true },
{ "logical", LOGICAL_KEYWORD, OP_NULL, true },
{ "logical_4", LOGICAL_S4_KEYWORD, OP_NULL, true },
{ "logical_8", LOGICAL_S8_KEYWORD, OP_NULL, true },
{ "real", REAL_KEYWORD, OP_NULL, true },
{ "real_4", REAL_S4_KEYWORD, OP_NULL, true },
{ "real_8", REAL_S8_KEYWORD, OP_NULL, true },
{ "real_16", REAL_S16_KEYWORD, OP_NULL, true },
{ "single", SINGLE, OP_NULL, true },
{ "double", DOUBLE, OP_NULL, true },
{ "precision", PRECISION, OP_NULL, true },
}
#define INT_S4_KEYWORD
Definition f-exp.c:248
#define REAL_S8_KEYWORD
Definition f-exp.c:257
#define CHARACTER
Definition f-exp.c:269
#define INT_S2_KEYWORD
Definition f-exp.c:246
#define COMPLEX_S16_KEYWORD
Definition f-exp.c:262
#define LOGICAL_S2_KEYWORD
Definition f-exp.c:251
#define REAL_S16_KEYWORD
Definition f-exp.c:258
#define LOGICAL_S1_KEYWORD
Definition f-exp.c:250
#define LOGICAL_KEYWORD
Definition f-exp.c:252
#define INT_S8_KEYWORD
Definition f-exp.c:249
#define COMPLEX_S8_KEYWORD
Definition f-exp.c:261
#define COMPLEX_KEYWORD
Definition f-exp.c:259
#define INT_S1_KEYWORD
Definition f-exp.c:245
#define LOGICAL_S4_KEYWORD
Definition f-exp.c:253
#define DOUBLE
Definition f-exp.c:267
#define COMPLEX_S4_KEYWORD
Definition f-exp.c:260
#define REAL_S4_KEYWORD
Definition f-exp.c:256
#define PRECISION
Definition f-exp.c:268
#define SINGLE
Definition f-exp.c:266
#define INT_KEYWORD
Definition f-exp.c:247
#define LOGICAL_S8_KEYWORD
Definition f-exp.c:254
#define REAL_KEYWORD
Definition f-exp.c:255

Definition at line 3190 of file f-exp.c.

Referenced by yylex().

◆ fortran_operators

const struct f_token fortran_operators[]
static
Initial value:
=
{
{ ".and.", BOOL_AND, OP_NULL, false },
{ ".or.", BOOL_OR, OP_NULL, false },
{ ".not.", BOOL_NOT, OP_NULL, false },
{ ".eq.", EQUAL, OP_NULL, false },
{ ".eqv.", EQUAL, OP_NULL, false },
{ ".neqv.", NOTEQUAL, OP_NULL, false },
{ ".xor.", NOTEQUAL, OP_NULL, false },
{ "==", EQUAL, OP_NULL, false },
{ ".ne.", NOTEQUAL, OP_NULL, false },
{ "/=", NOTEQUAL, OP_NULL, false },
{ ".le.", LEQ, OP_NULL, false },
{ "<=", LEQ, OP_NULL, false },
{ ".ge.", GEQ, OP_NULL, false },
{ ">=", GEQ, OP_NULL, false },
{ ".gt.", GREATERTHAN, OP_NULL, false },
{ ">", GREATERTHAN, OP_NULL, false },
{ ".lt.", LESSTHAN, OP_NULL, false },
{ "<", LESSTHAN, OP_NULL, false },
{ "**", STARSTAR, BINOP_EXP, false },
}
#define BOOL_NOT
Definition f-exp.c:265
#define LEQ
Definition f-exp.c:281
#define BOOL_AND
Definition f-exp.c:263
#define NOTEQUAL
Definition f-exp.c:278
#define GREATERTHAN
Definition f-exp.c:280
#define EQUAL
Definition f-exp.c:277
#define BOOL_OR
Definition f-exp.c:264
#define STARSTAR
Definition f-exp.c:285
#define GEQ
Definition f-exp.c:282
#define LESSTHAN
Definition f-exp.c:279

Definition at line 3127 of file f-exp.c.

Referenced by yylex().

◆ last_was_structop

bool last_was_structop
static

Definition at line 3298 of file f-exp.c.

Referenced by yylex().

◆ paren_depth

int paren_depth
static

Definition at line 99 of file f-exp.c.

Referenced by yylex().

◆ pstate

struct parser_state* pstate = NULL
static

◆ saw_name_at_eof

bool saw_name_at_eof
static

Definition at line 3294 of file f-exp.c.

Referenced by yylex().

◆ tempbuf

char* tempbuf
static

Definition at line 3221 of file f-exp.c.

Referenced by growbuf_by_size(), and match_string_literal().

◆ tempbufindex

int tempbufindex
static

Definition at line 3223 of file f-exp.c.

Referenced by match_string_literal(), and yylex().

◆ tempbufsize

int tempbufsize
static

Definition at line 3222 of file f-exp.c.

Referenced by growbuf_by_size(), and yylex().

◆ type_stack

struct type_stack* type_stack
static

Definition at line 102 of file f-exp.c.

◆ yychar

int yychar

Definition at line 1415 of file f-exp.c.

Referenced by yyparse().

◆ yycheck

const yytype_int16 yycheck[]
static

Definition at line 1055 of file f-exp.c.

Referenced by yyparse().

◆ yydebug

int yydebug

Definition at line 1365 of file f-exp.c.

◆ yydefact

const yytype_int8 yydefact[]
static
Initial value:
=
{
0, 61, 63, 68, 67, 113, 85, 62, 0, 0,
86, 87, 88, 89, 90, 92, 93, 94, 95, 96,
97, 98, 99, 100, 101, 102, 103, 104, 0, 0,
0, 91, 65, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 3, 2, 64, 4, 70, 71, 69,
0, 11, 0, 9, 107, 105, 108, 106, 0, 0,
17, 19, 7, 8, 6, 0, 0, 0, 10, 1,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 13, 75, 73, 0, 72, 77, 82, 0,
0, 0, 0, 21, 21, 0, 5, 35, 0, 57,
58, 60, 59, 56, 55, 54, 48, 49, 52, 53,
50, 51, 46, 47, 40, 44, 45, 42, 43, 41,
111, 112, 39, 37, 21, 76, 80, 74, 0, 83,
109, 0, 0, 0, 81, 66, 12, 15, 0, 29,
22, 0, 23, 0, 34, 36, 38, 0, 0, 78,
0, 84, 0, 0, 28, 27, 0, 18, 20, 14,
0, 110, 16, 33, 0, 0, 26, 24, 25, 79,
32, 31, 0, 30
}

Definition at line 918 of file f-exp.c.

Referenced by yyparse().

◆ yydefgoto

const yytype_uint8 yydefgoto[]
static
Initial value:
=
{
0, 42, 43, 150, 134, 103, 104, 151, 152, 66,
45, 140, 47, 96, 97, 98, 48, 142, 133, 49
}

Definition at line 949 of file f-exp.c.

Referenced by yyparse().

◆ yylval

f_exp_YYSTYPE yylval

Definition at line 1418 of file f-exp.c.

Referenced by match_string_literal(), yylex(), and yyparse().

◆ yynerrs

int yynerrs

Definition at line 1420 of file f-exp.c.

Referenced by yyparse().

◆ yypact

const yytype_int16 yypact[]
static
Initial value:
=
{
249, -103, -103, -103, -103, -103, -103, -103, 291, -62,
-103, -103, -103, -103, -103, -103, -103, -103, -103, -103,
-103, -103, -103, -103, -103, -103, -103, -103, 333, 6,
18, -103, -103, -61, -33, -26, -21, 333, 333, 333,
249, 333, 56, -103, 718, -103, -103, -103, -6, -103,
249, -20, 333, -20, -103, -103, -103, -103, 333, 333,
-103, -103, -20, -20, -20, 567, -16, -4, -20, -103,
333, 333, 333, 333, 333, 333, 333, 333, 333, 333,
333, 333, 333, 333, 333, 333, 333, 333, 333, 333,
333, 60, -103, -6, -2, 432, -103, 29, -103, 40,
373, 605, 681, 88, 88, 333, -103, -103, 333, 802,
753, 718, 718, 821, 839, 856, 733, 733, 53, 53,
53, 53, 133, 133, 72, 38, 38, 58, 58, 58,
-103, -103, -103, 54, 88, -103, -103, -103, 63, -103,
-103, 59, -40, -5, -103, 375, -103, -103, 333, 166,
456, -18, -103, -9, 718, -20, -103, 51, 104, -103,
812, -103, 643, 333, 493, 180, 88, -103, -103, -103,
75, -103, -103, 718, 333, 333, 530, 456, -103, -103,
718, 718, 333, 718
}

Definition at line 892 of file f-exp.c.

Referenced by yyparse().

◆ yypgoto

const yytype_int8 yypgoto[]
static
Initial value:
=
{
-103, -103, -103, 0, -103, -103, -103, -102, -41, -103,
-103, 4, -103, 48, -103, 49, -103, -103, -103, -103
}

Definition at line 942 of file f-exp.c.

Referenced by yyparse().

◆ yyr1

const yytype_int8 yyr1[]
static
Initial value:
=
{
0, 72, 73, 73, 74, 75, 75, 75, 75, 75,
75, 75, 75, 76, 75, 75, 75, 77, 75, 78,
75, 79, 79, 79, 79, 79, 80, 80, 80, 80,
80, 80, 80, 80, 81, 75, 75, 75, 75, 75,
75, 75, 75, 75, 75, 75, 75, 75, 75, 75,
75, 75, 75, 75, 75, 75, 75, 75, 75, 75,
75, 75, 75, 75, 75, 75, 75, 75, 75, 82,
83, 84, 84, 85, 85, 85, 85, 85, 86, 86,
86, 86, 86, 87, 87, 88, 88, 88, 88, 88,
88, 88, 88, 88, 88, 88, 88, 88, 88, 88,
88, 88, 88, 88, 88, 88, 88, 88, 88, 89,
89, 90, 90, 91
}

Definition at line 1178 of file f-exp.c.

Referenced by yyparse().

◆ yyr2

const yytype_int8 yyr2[]
static
Initial value:
=
{
0, 2, 1, 1, 1, 3, 2, 2, 2, 2,
2, 2, 4, 0, 5, 4, 6, 0, 5, 0,
5, 0, 1, 1, 3, 3, 3, 2, 2, 1,
5, 4, 4, 3, 3, 3, 4, 3, 4, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 1, 1, 1, 1, 1, 4, 1, 1, 1,
1, 1, 2, 1, 2, 1, 2, 1, 3, 5,
2, 2, 1, 2, 3, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 2, 2, 2, 2, 1,
3, 1, 1, 1
}

Definition at line 1195 of file f-exp.c.

Referenced by yy_reduce_print(), and yyparse().

◆ yyrline

const yytype_int16 yyrline[]
static
Initial value:
=
{
0, 219, 219, 220, 223, 227, 232, 236, 240, 244,
248, 252, 256, 266, 265, 276, 282, 289, 288, 309,
308, 332, 335, 339, 343, 347, 353, 363, 372, 381,
392, 404, 416, 428, 440, 444, 454, 461, 468, 478,
490, 494, 498, 502, 506, 510, 514, 518, 522, 526,
530, 534, 538, 542, 546, 550, 554, 558, 563, 567,
571, 580, 587, 597, 606, 609, 613, 622, 626, 633,
641, 644, 645, 697, 699, 701, 703, 705, 708, 710,
712, 714, 716, 720, 722, 727, 729, 731, 733, 735,
737, 739, 741, 743, 745, 747, 749, 751, 753, 755,
757, 759, 761, 763, 765, 767, 769, 771, 773, 778,
783, 791, 793, 797
}

Definition at line 824 of file f-exp.c.

Referenced by yy_reduce_print().

◆ yystos

const yytype_int8 yystos[]
static
Initial value:
=
{
0, 3, 4, 5, 6, 7, 8, 10, 11, 12,
14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
24, 25, 26, 27, 28, 29, 30, 31, 34, 35,
36, 38, 39, 41, 42, 43, 44, 51, 62, 63,
68, 70, 73, 74, 75, 82, 83, 84, 88, 91,
68, 75, 68, 75, 28, 37, 28, 37, 68, 68,
68, 68, 75, 75, 75, 75, 81, 83, 75, 0,
32, 33, 40, 47, 49, 50, 51, 52, 53, 54,
55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
65, 66, 68, 51, 63, 68, 85, 86, 87, 83,
75, 75, 75, 77, 78, 45, 69, 69, 69, 75,
75, 75, 75, 75, 75, 75, 75, 75, 75, 75,
75, 75, 75, 75, 75, 75, 75, 75, 75, 75,
7, 8, 9, 90, 76, 85, 3, 85, 12, 69,
83, 85, 89, 68, 87, 69, 69, 69, 45, 71,
75, 79, 80, 79, 75, 75, 9, 79, 47, 69,
45, 69, 75, 71, 75, 71, 45, 69, 69, 69,
3, 83, 69, 75, 71, 71, 75, 75, 80, 69,
75, 75, 71, 75
}

Definition at line 1154 of file f-exp.c.

◆ yytable

const yytype_uint8 yytable[]
static

Definition at line 958 of file f-exp.c.

Referenced by yyparse().

◆ yytname

const char* const yytname[]
static
Initial value:
=
{
"\"end of file\"", "error", "\"invalid token\"", "INT", "FLOAT",
"STRING_LITERAL", "BOOLEAN_LITERAL", "NAME", "TYPENAME", "COMPLETE",
"NAME_OR_INT", "SIZEOF", "KIND", "ERROR", "INT_S1_KEYWORD",
"INT_S2_KEYWORD", "INT_KEYWORD", "INT_S4_KEYWORD", "INT_S8_KEYWORD",
"LOGICAL_S1_KEYWORD", "LOGICAL_S2_KEYWORD", "LOGICAL_KEYWORD",
"LOGICAL_S4_KEYWORD", "LOGICAL_S8_KEYWORD", "REAL_KEYWORD",
"REAL_S4_KEYWORD", "REAL_S8_KEYWORD", "REAL_S16_KEYWORD",
"COMPLEX_KEYWORD", "COMPLEX_S4_KEYWORD", "COMPLEX_S8_KEYWORD",
"COMPLEX_S16_KEYWORD", "BOOL_AND", "BOOL_OR", "BOOL_NOT", "SINGLE",
"DOUBLE", "PRECISION", "CHARACTER", "DOLLAR_VARIABLE", "ASSIGN_MODIFY",
"UNOP_INTRINSIC", "BINOP_INTRINSIC", "UNOP_OR_BINOP_INTRINSIC",
"UNOP_OR_BINOP_OR_TERNOP_INTRINSIC", "','", "ABOVE_COMMA", "'='", "'?'",
"'|'", "'^'", "'&'", "EQUAL", "NOTEQUAL", "LESSTHAN", "GREATERTHAN",
"LEQ", "GEQ", "LSH", "RSH", "'@'", "'+'", "'-'", "'*'", "'/'",
"STARSTAR", "'%'", "UNARY", "'('", "')'", "'~'", "':'", "$accept",
"start", "type_exp", "exp", "$@1", "$@2", "$@3", "arglist", "subrange",
"complexnum", "variable", "type", "ptype", "abs_decl", "direct_abs_decl",
"func_mod", "typebase", "nonempty_typelist", "name", "name_not_typename", YY_NULLPTRPTR
}
#define YY_NULLPTRPTR
Definition f-exp.c:151

Definition at line 851 of file f-exp.c.

Referenced by yysymbol_name().

◆ yytranslate

const yytype_int8 yytranslate[]
static

Definition at line 786 of file f-exp.c.