wcalc  2.5
About: Wcalc is a natural-expression command-line calculator.
  Fossies Dox: wcalc-2.5.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

parser.c File Reference
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include "number.h"
#include <stdarg.h>
#include <math.h>
#include <float.h>
#include <unistd.h>
#include "calculator.h"
#include "variables.h"
#include "files.h"
#include "conversion.h"
#include "number_formatting.h"
#include "output.h"
#include <stddef.h>
Include dependency graph for parser.c:

Go to the source code of this file.

Data Structures

union  YYSTYPE
 
union  yyalloc
 

Macros

#define YYBISON   1
 
#define YYBISON_VERSION   "3.0.2"
 
#define YYSKELETON_NAME   "yacc.c"
 
#define YYPURE   0
 
#define YYPUSH   0
 
#define YYPULL   1
 
#define YYDEBUG   1
 
#define YY_NULLPTR   0
 
#define YYERROR_VERBOSE   0
 
#define YY_YY__SVN_SRC_COMMON_PARSER_H_INCLUDED
 
#define YYTOKENTYPE
 
#define DEC_CMD   258
 
#define OCT_CMD   259
 
#define HEX_CMD   260
 
#define BIN_CMD   261
 
#define DISPLAY_PREFS_CMD   262
 
#define RADIAN_CMD   263
 
#define REMEMBER_CMD   264
 
#define LISTVAR_CMD   265
 
#define STORE_CMD   266
 
#define CMOD_CMD   267
 
#define PRINT_HELP_CMD   268
 
#define PREFIX_CMD   269
 
#define INT_CMD   270
 
#define VERBOSE_CMD   271
 
#define DELIM_CMD   272
 
#define ASSERT_CMD   273
 
#define ENG_CMD   274
 
#define HLIMIT_CMD   275
 
#define ROUNDING_INDICATION_CMD   276
 
#define PRECISION_CMD   277
 
#define BITS_CMD   278
 
#define BASE_CMD   279
 
#define GUARD_CMD   280
 
#define CONVERT_CMD   281
 
#define EOLN   282
 
#define OPEN_PARENTHESES   283
 
#define CLOSE_PARENTHESES   284
 
#define OPEN_BRACE   285
 
#define CLOSE_BRACE   286
 
#define OPEN_BRACKET   287
 
#define CLOSE_BRACKET   288
 
#define WPLUS   289
 
#define WMINUS   290
 
#define WMULT   291
 
#define WDIV   292
 
#define WMOD   293
 
#define EQUALS_SIGN   294
 
#define WPOW   295
 
#define WEXP   296
 
#define WSQR   297
 
#define WOR   298
 
#define WAND   299
 
#define WEQUAL   300
 
#define WNEQUAL   301
 
#define WGT   302
 
#define WLT   303
 
#define WGEQ   304
 
#define WLEQ   305
 
#define WLSHFT   306
 
#define WRSHFT   307
 
#define WBOR   308
 
#define WBAND   309
 
#define WBXOR   310
 
#define WBNOT   311
 
#define WNOT   312
 
#define WLOG   313
 
#define WLN   314
 
#define WROUND   315
 
#define WABS   316
 
#define WSQRT   317
 
#define WCEIL   318
 
#define WFLOOR   319
 
#define WCBRT   320
 
#define WLOGTWO   321
 
#define WBANG   322
 
#define WSIN   323
 
#define WCOS   324
 
#define WTAN   325
 
#define WASIN   326
 
#define WACOS   327
 
#define WATAN   328
 
#define WSINH   329
 
#define WCOSH   330
 
#define WTANH   331
 
#define WASINH   332
 
#define WACOSH   333
 
#define WATANH   334
 
#define WCOT   335
 
#define WACOT   336
 
#define WCOTH   337
 
#define WACOTH   338
 
#define WRAND   339
 
#define WIRAND   340
 
#define WFACT   341
 
#define WCOMP   342
 
#define WSEC   343
 
#define WCSC   344
 
#define WASEC   345
 
#define WACSC   346
 
#define WSECH   347
 
#define WCSCH   348
 
#define WASECH   349
 
#define WACSCH   350
 
#define WEINT   351
 
#define WGAMMA   352
 
#define WLNGAMMA   353
 
#define WZETA   354
 
#define WSINC   355
 
#define NUMBER   356
 
#define VARIABLE   357
 
#define STRING   358
 
#define OPEN_CMD   359
 
#define SAVE_CMD   360
 
#define ASSIGNMENT   361
 
#define IDSEP_CMD   362
 
#define DSEP_CMD   363
 
#define ITSEP_CMD   364
 
#define TSEP_CMD   365
 
#define WNEG   366
 
#define YYSTYPE_IS_TRIVIAL   1
 
#define YYSTYPE_IS_DECLARED   1
 
#define YYSIZE_T   size_t
 
#define YYSIZE_MAXIMUM   ((YYSIZE_T) -1)
 
#define YY_(Msgid)   Msgid
 
#define YY_ATTRIBUTE(Spec)   /* empty */
 
#define YY_ATTRIBUTE_PURE   YY_ATTRIBUTE ((__pure__))
 
#define YY_ATTRIBUTE_UNUSED   YY_ATTRIBUTE ((__unused__))
 
#define _Noreturn   YY_ATTRIBUTE ((__noreturn__))
 
#define YYUSE(E)   ((void) (E))
 
#define YY_INITIAL_VALUE(Value)   Value
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_END
 
#define YYSTACK_ALLOC   YYMALLOC
 
#define YYSTACK_FREE   YYFREE
 
#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM
 
#define YYMALLOC   malloc
 
#define YYFREE   free
 
#define YYSTACK_GAP_MAXIMUM   (sizeof (union yyalloc) - 1)
 
#define YYSTACK_BYTES(N)
 
#define YYCOPY_NEEDED   1
 
#define YYSTACK_RELOCATE(Stack_alloc, Stack)
 
#define YYCOPY(Dst, Src, Count)
 
#define YYFINAL   111
 
#define YYLAST   997
 
#define YYNTOKENS   112
 
#define YYNNTS   17
 
#define YYNRULES   133
 
#define YYNSTATES   176
 
#define YYUNDEFTOK   2
 
#define YYMAXUTOK   366
 
#define YYTRANSLATE(YYX)   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
 
#define YYPACT_NINF   -91
 
#define yypact_value_is_default(Yystate)   (!!((Yystate) == (-91)))
 
#define YYTABLE_NINF   -5
 
#define yytable_value_is_error(Yytable_value)   0
 
#define yyerrok   (yyerrstatus = 0)
 
#define yyclearin   (yychar = YYEMPTY)
 
#define YYEMPTY   (-2)
 
#define YYEOF   0
 
#define YYACCEPT   goto yyacceptlab
 
#define YYABORT   goto yyabortlab
 
#define YYERROR   goto yyerrorlab
 
#define YYRECOVERING()   (!!yyerrstatus)
 
#define YYBACKUP(Token, Value)
 
#define YYTERROR   1
 
#define YYERRCODE   256
 
#define YYFPRINTF   fprintf
 
#define YYDPRINTF(Args)
 
#define YY_LOCATION_PRINT(File, Loc)   ((void) 0)
 
#define YY_SYMBOL_PRINT(Title, Type, 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))
 

Typedefs

typedef union YYSTYPE YYSTYPE
 
typedef unsigned char yytype_uint8
 
typedef signed char yytype_int8
 
typedef unsigned short int yytype_uint16
 
typedef short int yytype_int16
 

Enumerations

enum  yytokentype {
  DEC_CMD = 258, OCT_CMD = 259, HEX_CMD = 260, BIN_CMD = 261,
  DISPLAY_PREFS_CMD = 262, RADIAN_CMD = 263, REMEMBER_CMD = 264, LISTVAR_CMD = 265,
  STORE_CMD = 266, CMOD_CMD = 267, PRINT_HELP_CMD = 268, PREFIX_CMD = 269,
  INT_CMD = 270, VERBOSE_CMD = 271, DELIM_CMD = 272, ASSERT_CMD = 273,
  ENG_CMD = 274, HLIMIT_CMD = 275, ROUNDING_INDICATION_CMD = 276, PRECISION_CMD = 277,
  BITS_CMD = 278, BASE_CMD = 279, GUARD_CMD = 280, CONVERT_CMD = 281,
  EOLN = 282, OPEN_PARENTHESES = 283, CLOSE_PARENTHESES = 284, OPEN_BRACE = 285,
  CLOSE_BRACE = 286, OPEN_BRACKET = 287, CLOSE_BRACKET = 288, WPLUS = 289,
  WMINUS = 290, WMULT = 291, WDIV = 292, WMOD = 293,
  EQUALS_SIGN = 294, WPOW = 295, WEXP = 296, WSQR = 297,
  WOR = 298, WAND = 299, WEQUAL = 300, WNEQUAL = 301,
  WGT = 302, WLT = 303, WGEQ = 304, WLEQ = 305,
  WLSHFT = 306, WRSHFT = 307, WBOR = 308, WBAND = 309,
  WBXOR = 310, WBNOT = 311, WNOT = 312, WLOG = 313,
  WLN = 314, WROUND = 315, WABS = 316, WSQRT = 317,
  WCEIL = 318, WFLOOR = 319, WCBRT = 320, WLOGTWO = 321,
  WBANG = 322, WSIN = 323, WCOS = 324, WTAN = 325,
  WASIN = 326, WACOS = 327, WATAN = 328, WSINH = 329,
  WCOSH = 330, WTANH = 331, WASINH = 332, WACOSH = 333,
  WATANH = 334, WCOT = 335, WACOT = 336, WCOTH = 337,
  WACOTH = 338, WRAND = 339, WIRAND = 340, WFACT = 341,
  WCOMP = 342, WSEC = 343, WCSC = 344, WASEC = 345,
  WACSC = 346, WSECH = 347, WCSCH = 348, WASECH = 349,
  WACSCH = 350, WEINT = 351, WGAMMA = 352, WLNGAMMA = 353,
  WZETA = 354, WSINC = 355, NUMBER = 356, VARIABLE = 357,
  STRING = 358, OPEN_CMD = 359, SAVE_CMD = 360, ASSIGNMENT = 361,
  IDSEP_CMD = 362, DSEP_CMD = 363, ITSEP_CMD = 364, TSEP_CMD = 365,
  WNEG = 366, DEC_CMD = 258, OCT_CMD = 259, HEX_CMD = 260,
  BIN_CMD = 261, DISPLAY_PREFS_CMD = 262, RADIAN_CMD = 263, REMEMBER_CMD = 264,
  LISTVAR_CMD = 265, STORE_CMD = 266, CMOD_CMD = 267, PRINT_HELP_CMD = 268,
  PREFIX_CMD = 269, INT_CMD = 270, VERBOSE_CMD = 271, DELIM_CMD = 272,
  ASSERT_CMD = 273, ENG_CMD = 274, HLIMIT_CMD = 275, ROUNDING_INDICATION_CMD = 276,
  PRECISION_CMD = 277, BITS_CMD = 278, BASE_CMD = 279, GUARD_CMD = 280,
  CONVERT_CMD = 281, EOLN = 282, OPEN_PARENTHESES = 283, CLOSE_PARENTHESES = 284,
  OPEN_BRACE = 285, CLOSE_BRACE = 286, OPEN_BRACKET = 287, CLOSE_BRACKET = 288,
  WPLUS = 289, WMINUS = 290, WMULT = 291, WDIV = 292,
  WMOD = 293, EQUALS_SIGN = 294, WPOW = 295, WEXP = 296,
  WSQR = 297, WOR = 298, WAND = 299, WEQUAL = 300,
  WNEQUAL = 301, WGT = 302, WLT = 303, WGEQ = 304,
  WLEQ = 305, WLSHFT = 306, WRSHFT = 307, WBOR = 308,
  WBAND = 309, WBXOR = 310, WBNOT = 311, WNOT = 312,
  WLOG = 313, WLN = 314, WROUND = 315, WABS = 316,
  WSQRT = 317, WCEIL = 318, WFLOOR = 319, WCBRT = 320,
  WLOGTWO = 321, WBANG = 322, WSIN = 323, WCOS = 324,
  WTAN = 325, WASIN = 326, WACOS = 327, WATAN = 328,
  WSINH = 329, WCOSH = 330, WTANH = 331, WASINH = 332,
  WACOSH = 333, WATANH = 334, WCOT = 335, WACOT = 336,
  WCOTH = 337, WACOTH = 338, WRAND = 339, WIRAND = 340,
  WFACT = 341, WCOMP = 342, WSEC = 343, WCSC = 344,
  WASEC = 345, WACSC = 346, WSECH = 347, WCSCH = 348,
  WASECH = 349, WACSCH = 350, WEINT = 351, WGAMMA = 352,
  WLNGAMMA = 353, WZETA = 354, WSINC = 355, NUMBER = 356,
  VARIABLE = 357, STRING = 358, OPEN_CMD = 359, SAVE_CMD = 360,
  ASSIGNMENT = 361, IDSEP_CMD = 362, DSEP_CMD = 363, ITSEP_CMD = 364,
  TSEP_CMD = 365, WNEG = 366
}
 

Functions

int yylex (void)
 
int yyerror (char *error_string,...)
 
int yyparse (void)
 
void * malloc (size_t)
 
void free (void *)
 
static void yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep)
 
static void yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep)
 
static void yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
 
static void yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule)
 
static void yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
 

Variables

int lines = 1
 
int synerrors = 0
 
short scanerror = 0
 
char * errstring = NULL
 
int errloc = -1
 
int show_line_numbers = 0
 
int yydebug
 
YYSTYPE yylval
 
static const yytype_uint8 yytranslate []
 
static const yytype_uint16 yyrline []
 
static const char *const yytname []
 
static const yytype_int16 yypact []
 
static const yytype_uint8 yydefact []
 
static const yytype_int16 yypgoto []
 
static const yytype_int16 yydefgoto []
 
static const yytype_int16 yytable []
 
static const yytype_int16 yycheck []
 
static const yytype_uint8 yystos []
 
static const yytype_uint8 yyr1 []
 
static const yytype_uint8 yyr2 []
 
int yychar
 
int yynerrs
 

Macro Definition Documentation

◆ _Noreturn

#define _Noreturn   YY_ATTRIBUTE ((__noreturn__))

Definition at line 484 of file parser.c.

◆ ASSERT_CMD

#define ASSERT_CMD   273

Definition at line 278 of file parser.c.

◆ ASSIGNMENT

#define ASSIGNMENT   361

Definition at line 366 of file parser.c.

◆ BASE_CMD

#define BASE_CMD   279

Definition at line 284 of file parser.c.

◆ BIN_CMD

#define BIN_CMD   261

Definition at line 266 of file parser.c.

◆ BITS_CMD

#define BITS_CMD   278

Definition at line 283 of file parser.c.

◆ CLOSE_BRACE

#define CLOSE_BRACE   286

Definition at line 291 of file parser.c.

◆ CLOSE_BRACKET

#define CLOSE_BRACKET   288

Definition at line 293 of file parser.c.

◆ CLOSE_PARENTHESES

#define CLOSE_PARENTHESES   284

Definition at line 289 of file parser.c.

◆ CMOD_CMD

#define CMOD_CMD   267

Definition at line 272 of file parser.c.

◆ CONVERT_CMD

#define CONVERT_CMD   281

Definition at line 286 of file parser.c.

◆ DEC_CMD

#define DEC_CMD   258

Definition at line 263 of file parser.c.

◆ DELIM_CMD

#define DELIM_CMD   272

Definition at line 277 of file parser.c.

◆ DISPLAY_PREFS_CMD

#define DISPLAY_PREFS_CMD   262

Definition at line 267 of file parser.c.

◆ DSEP_CMD

#define DSEP_CMD   363

Definition at line 368 of file parser.c.

◆ ENG_CMD

#define ENG_CMD   274

Definition at line 279 of file parser.c.

◆ EOLN

#define EOLN   282

Definition at line 287 of file parser.c.

◆ EQUALS_SIGN

#define EQUALS_SIGN   294

Definition at line 299 of file parser.c.

◆ GUARD_CMD

#define GUARD_CMD   280

Definition at line 285 of file parser.c.

◆ HEX_CMD

#define HEX_CMD   260

Definition at line 265 of file parser.c.

◆ HLIMIT_CMD

#define HLIMIT_CMD   275

Definition at line 280 of file parser.c.

◆ IDSEP_CMD

#define IDSEP_CMD   362

Definition at line 367 of file parser.c.

◆ INT_CMD

#define INT_CMD   270

Definition at line 275 of file parser.c.

◆ ITSEP_CMD

#define ITSEP_CMD   364

Definition at line 369 of file parser.c.

◆ LISTVAR_CMD

#define LISTVAR_CMD   265

Definition at line 270 of file parser.c.

◆ NUMBER

#define NUMBER   356

Definition at line 361 of file parser.c.

◆ OCT_CMD

#define OCT_CMD   259

Definition at line 264 of file parser.c.

◆ OPEN_BRACE

#define OPEN_BRACE   285

Definition at line 290 of file parser.c.

◆ OPEN_BRACKET

#define OPEN_BRACKET   287

Definition at line 292 of file parser.c.

◆ OPEN_CMD

#define OPEN_CMD   359

Definition at line 364 of file parser.c.

◆ OPEN_PARENTHESES

#define OPEN_PARENTHESES   283

Definition at line 288 of file parser.c.

◆ PRECISION_CMD

#define PRECISION_CMD   277

Definition at line 282 of file parser.c.

◆ PREFIX_CMD

#define PREFIX_CMD   269

Definition at line 274 of file parser.c.

◆ PRINT_HELP_CMD

#define PRINT_HELP_CMD   268

Definition at line 273 of file parser.c.

◆ RADIAN_CMD

#define RADIAN_CMD   263

Definition at line 268 of file parser.c.

◆ REMEMBER_CMD

#define REMEMBER_CMD   264

Definition at line 269 of file parser.c.

◆ ROUNDING_INDICATION_CMD

#define ROUNDING_INDICATION_CMD   276

Definition at line 281 of file parser.c.

◆ SAVE_CMD

#define SAVE_CMD   360

Definition at line 365 of file parser.c.

◆ STORE_CMD

#define STORE_CMD   266

Definition at line 271 of file parser.c.

◆ STRING

#define STRING   358

Definition at line 363 of file parser.c.

◆ TSEP_CMD

#define TSEP_CMD   365

Definition at line 370 of file parser.c.

◆ VARIABLE

#define VARIABLE   357

Definition at line 362 of file parser.c.

◆ VERBOSE_CMD

#define VERBOSE_CMD   271

Definition at line 276 of file parser.c.

◆ WABS

#define WABS   316

Definition at line 321 of file parser.c.

◆ WACOS

#define WACOS   327

Definition at line 332 of file parser.c.

◆ WACOSH

#define WACOSH   333

Definition at line 338 of file parser.c.

◆ WACOT

#define WACOT   336

Definition at line 341 of file parser.c.

◆ WACOTH

#define WACOTH   338

Definition at line 343 of file parser.c.

◆ WACSC

#define WACSC   346

Definition at line 351 of file parser.c.

◆ WACSCH

#define WACSCH   350

Definition at line 355 of file parser.c.

◆ WAND

#define WAND   299

Definition at line 304 of file parser.c.

◆ WASEC

#define WASEC   345

Definition at line 350 of file parser.c.

◆ WASECH

#define WASECH   349

Definition at line 354 of file parser.c.

◆ WASIN

#define WASIN   326

Definition at line 331 of file parser.c.

◆ WASINH

#define WASINH   332

Definition at line 337 of file parser.c.

◆ WATAN

#define WATAN   328

Definition at line 333 of file parser.c.

◆ WATANH

#define WATANH   334

Definition at line 339 of file parser.c.

◆ WBAND

#define WBAND   309

Definition at line 314 of file parser.c.

◆ WBANG

#define WBANG   322

Definition at line 327 of file parser.c.

◆ WBNOT

#define WBNOT   311

Definition at line 316 of file parser.c.

◆ WBOR

#define WBOR   308

Definition at line 313 of file parser.c.

◆ WBXOR

#define WBXOR   310

Definition at line 315 of file parser.c.

◆ WCBRT

#define WCBRT   320

Definition at line 325 of file parser.c.

◆ WCEIL

#define WCEIL   318

Definition at line 323 of file parser.c.

◆ WCOMP

#define WCOMP   342

Definition at line 347 of file parser.c.

◆ WCOS

#define WCOS   324

Definition at line 329 of file parser.c.

◆ WCOSH

#define WCOSH   330

Definition at line 335 of file parser.c.

◆ WCOT

#define WCOT   335

Definition at line 340 of file parser.c.

◆ WCOTH

#define WCOTH   337

Definition at line 342 of file parser.c.

◆ WCSC

#define WCSC   344

Definition at line 349 of file parser.c.

◆ WCSCH

#define WCSCH   348

Definition at line 353 of file parser.c.

◆ WDIV

#define WDIV   292

Definition at line 297 of file parser.c.

◆ WEINT

#define WEINT   351

Definition at line 356 of file parser.c.

◆ WEQUAL

#define WEQUAL   300

Definition at line 305 of file parser.c.

◆ WEXP

#define WEXP   296

Definition at line 301 of file parser.c.

◆ WFACT

#define WFACT   341

Definition at line 346 of file parser.c.

◆ WFLOOR

#define WFLOOR   319

Definition at line 324 of file parser.c.

◆ WGAMMA

#define WGAMMA   352

Definition at line 357 of file parser.c.

◆ WGEQ

#define WGEQ   304

Definition at line 309 of file parser.c.

◆ WGT

#define WGT   302

Definition at line 307 of file parser.c.

◆ WIRAND

#define WIRAND   340

Definition at line 345 of file parser.c.

◆ WLEQ

#define WLEQ   305

Definition at line 310 of file parser.c.

◆ WLN

#define WLN   314

Definition at line 319 of file parser.c.

◆ WLNGAMMA

#define WLNGAMMA   353

Definition at line 358 of file parser.c.

◆ WLOG

#define WLOG   313

Definition at line 318 of file parser.c.

◆ WLOGTWO

#define WLOGTWO   321

Definition at line 326 of file parser.c.

◆ WLSHFT

#define WLSHFT   306

Definition at line 311 of file parser.c.

◆ WLT

#define WLT   303

Definition at line 308 of file parser.c.

◆ WMINUS

#define WMINUS   290

Definition at line 295 of file parser.c.

◆ WMOD

#define WMOD   293

Definition at line 298 of file parser.c.

◆ WMULT

#define WMULT   291

Definition at line 296 of file parser.c.

◆ WNEG

#define WNEG   366

Definition at line 371 of file parser.c.

◆ WNEQUAL

#define WNEQUAL   301

Definition at line 306 of file parser.c.

◆ WNOT

#define WNOT   312

Definition at line 317 of file parser.c.

◆ WOR

#define WOR   298

Definition at line 303 of file parser.c.

◆ WPLUS

#define WPLUS   289

Definition at line 294 of file parser.c.

◆ WPOW

#define WPOW   295

Definition at line 300 of file parser.c.

◆ WRAND

#define WRAND   339

Definition at line 344 of file parser.c.

◆ WROUND

#define WROUND   315

Definition at line 320 of file parser.c.

◆ WRSHFT

#define WRSHFT   307

Definition at line 312 of file parser.c.

◆ WSEC

#define WSEC   343

Definition at line 348 of file parser.c.

◆ WSECH

#define WSECH   347

Definition at line 352 of file parser.c.

◆ WSIN

#define WSIN   323

Definition at line 328 of file parser.c.

◆ WSINC

#define WSINC   355

Definition at line 360 of file parser.c.

◆ WSINH

#define WSINH   329

Definition at line 334 of file parser.c.

◆ WSQR

#define WSQR   297

Definition at line 302 of file parser.c.

◆ WSQRT

#define WSQRT   317

Definition at line 322 of file parser.c.

◆ WTAN

#define WTAN   325

Definition at line 330 of file parser.c.

◆ WTANH

#define WTANH   331

Definition at line 336 of file parser.c.

◆ WZETA

#define WZETA   354

Definition at line 359 of file parser.c.

◆ YY_

#define YY_ (   Msgid)    Msgid

Definition at line 457 of file parser.c.

◆ YY_ATTRIBUTE

#define YY_ATTRIBUTE (   Spec)    /* empty */

Definition at line 467 of file parser.c.

◆ YY_ATTRIBUTE_PURE

#define YY_ATTRIBUTE_PURE   YY_ATTRIBUTE ((__pure__))

Definition at line 472 of file parser.c.

◆ YY_ATTRIBUTE_UNUSED

#define YY_ATTRIBUTE_UNUSED   YY_ATTRIBUTE ((__unused__))

Definition at line 476 of file parser.c.

◆ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN

#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN

Definition at line 507 of file parser.c.

◆ YY_IGNORE_MAYBE_UNINITIALIZED_END

#define YY_IGNORE_MAYBE_UNINITIALIZED_END

Definition at line 508 of file parser.c.

◆ YY_INITIAL_VALUE

#define YY_INITIAL_VALUE (   Value)    Value

Definition at line 504 of file parser.c.

◆ YY_LOCATION_PRINT

#define YY_LOCATION_PRINT (   File,
  Loc 
)    ((void) 0)

Definition at line 1176 of file parser.c.

◆ YY_NULLPTR

#define YY_NULLPTR   0

Definition at line 122 of file parser.c.

◆ YY_REDUCE_PRINT

#define YY_REDUCE_PRINT (   Rule)
Value:
do { \
if (yydebug) \
yy_reduce_print (yyssp, yyvsp, Rule); \
} while (0)

Definition at line 1273 of file parser.c.

◆ YY_STACK_PRINT

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

Definition at line 1242 of file parser.c.

◆ YY_SYMBOL_PRINT

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

Definition at line 1180 of file parser.c.

◆ YY_YY__SVN_SRC_COMMON_PARSER_H_INCLUDED

#define YY_YY__SVN_SRC_COMMON_PARSER_H_INCLUDED

Definition at line 137 of file parser.c.

◆ YYABORT

#define YYABORT   goto yyabortlab

Definition at line 1131 of file parser.c.

◆ YYACCEPT

#define YYACCEPT   goto yyacceptlab

Definition at line 1130 of file parser.c.

◆ 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")); \
YYERROR; \
} \
while (0)

Definition at line 1137 of file parser.c.

◆ YYBISON

#define YYBISON   1

Definition at line 44 of file parser.c.

◆ YYBISON_VERSION

#define YYBISON_VERSION   "3.0.2"

Definition at line 47 of file parser.c.

◆ yyclearin

#define yyclearin   (yychar = YYEMPTY)

Definition at line 1126 of file parser.c.

◆ YYCOPY

#define YYCOPY (   Dst,
  Src,
  Count 
)
Value:
do \
{ \
YYSIZE_T yyi; \
for (yyi = 0; yyi < (Count); yyi++) \
(Dst)[yyi] = (Src)[yyi]; \
} \
while (0)

Definition at line 631 of file parser.c.

◆ YYCOPY_NEEDED

#define YYCOPY_NEEDED   1

Definition at line 603 of file parser.c.

◆ YYDEBUG

#define YYDEBUG   1

Definition at line 102 of file parser.c.

◆ YYDPRINTF

#define YYDPRINTF (   Args)
Value:
do { \
if (yydebug) \
YYFPRINTF Args; \
} while (0)

Definition at line 1168 of file parser.c.

◆ YYEMPTY

#define YYEMPTY   (-2)

Definition at line 1127 of file parser.c.

◆ YYEOF

#define YYEOF   0

Definition at line 1128 of file parser.c.

◆ YYERRCODE

#define YYERRCODE   256

Definition at line 1156 of file parser.c.

◆ yyerrok

#define yyerrok   (yyerrstatus = 0)

Definition at line 1125 of file parser.c.

◆ YYERROR

#define YYERROR   goto yyerrorlab

Definition at line 1132 of file parser.c.

◆ YYERROR_VERBOSE

#define YYERROR_VERBOSE   0

Definition at line 131 of file parser.c.

◆ YYFINAL

#define YYFINAL   111

Definition at line 644 of file parser.c.

◆ YYFPRINTF

#define YYFPRINTF   fprintf

Definition at line 1165 of file parser.c.

◆ YYFREE

#define YYFREE   free

Definition at line 574 of file parser.c.

◆ YYINITDEPTH

#define YYINITDEPTH   200

Definition at line 1292 of file parser.c.

◆ YYLAST

#define YYLAST   997

Definition at line 646 of file parser.c.

◆ YYMALLOC

#define YYMALLOC   malloc

Definition at line 568 of file parser.c.

◆ YYMAXDEPTH

#define YYMAXDEPTH   10000

Definition at line 1303 of file parser.c.

◆ YYMAXUTOK

#define YYMAXUTOK   366

Definition at line 660 of file parser.c.

◆ YYNNTS

#define YYNNTS   17

Definition at line 651 of file parser.c.

◆ YYNRULES

#define YYNRULES   133

Definition at line 653 of file parser.c.

◆ YYNSTATES

#define YYNSTATES   176

Definition at line 655 of file parser.c.

◆ YYNTOKENS

#define YYNTOKENS   112

Definition at line 649 of file parser.c.

◆ YYPACT_NINF

#define YYPACT_NINF   -91

Definition at line 778 of file parser.c.

◆ yypact_value_is_default

#define yypact_value_is_default (   Yystate)    (!!((Yystate) == (-91)))

Definition at line 780 of file parser.c.

◆ YYPOPSTACK

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

◆ YYPULL

#define YYPULL   1

Definition at line 59 of file parser.c.

◆ YYPURE

#define YYPURE   0

Definition at line 53 of file parser.c.

◆ YYPUSH

#define YYPUSH   0

Definition at line 56 of file parser.c.

◆ YYRECOVERING

#define YYRECOVERING ( )    (!!yyerrstatus)

Definition at line 1135 of file parser.c.

◆ YYSIZE_MAXIMUM

#define YYSIZE_MAXIMUM   ((YYSIZE_T) -1)

Definition at line 447 of file parser.c.

◆ YYSIZE_T

#define YYSIZE_T   size_t

Definition at line 441 of file parser.c.

◆ YYSKELETON_NAME

#define YYSKELETON_NAME   "yacc.c"

Definition at line 50 of file parser.c.

◆ YYSTACK_ALLOC

#define YYSTACK_ALLOC   YYMALLOC

Definition at line 554 of file parser.c.

◆ YYSTACK_ALLOC_MAXIMUM

#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM

Definition at line 557 of file parser.c.

◆ YYSTACK_BYTES

#define YYSTACK_BYTES (   N)
Value:
((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \

Definition at line 599 of file parser.c.

◆ YYSTACK_FREE

#define YYSTACK_FREE   YYFREE

Definition at line 555 of file parser.c.

◆ YYSTACK_GAP_MAXIMUM

#define YYSTACK_GAP_MAXIMUM   (sizeof (union yyalloc) - 1)

Definition at line 595 of file parser.c.

◆ YYSTACK_RELOCATE

#define YYSTACK_RELOCATE (   Stack_alloc,
  Stack 
)
Value:
do \
{ \
YYSIZE_T yynewbytes; \
YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
Stack = &yyptr->Stack_alloc; \
yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
yyptr += yynewbytes / sizeof (*yyptr); \
} \
while (0)

Definition at line 610 of file parser.c.

◆ YYSTYPE_IS_DECLARED

#define YYSTYPE_IS_DECLARED   1

Definition at line 392 of file parser.c.

◆ YYSTYPE_IS_TRIVIAL

#define YYSTYPE_IS_TRIVIAL   1

Definition at line 391 of file parser.c.

◆ YYTABLE_NINF

#define YYTABLE_NINF   -5

Definition at line 783 of file parser.c.

◆ yytable_value_is_error

#define yytable_value_is_error (   Yytable_value)    0

Definition at line 785 of file parser.c.

◆ YYTERROR

#define YYTERROR   1

Definition at line 1155 of file parser.c.

◆ YYTOKENTYPE

#define YYTOKENTYPE

Definition at line 148 of file parser.c.

◆ YYTRANSLATE

#define YYTRANSLATE (   YYX)    ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)

Definition at line 662 of file parser.c.

◆ YYUNDEFTOK

#define YYUNDEFTOK   2

Definition at line 659 of file parser.c.

◆ YYUSE

#define YYUSE (   E)    ((void) (E))

Definition at line 490 of file parser.c.

Typedef Documentation

◆ YYSTYPE

typedef union YYSTYPE YYSTYPE

Definition at line 375 of file parser.c.

◆ yytype_int16

typedef short int yytype_int16

Definition at line 431 of file parser.c.

◆ yytype_int8

typedef signed char yytype_int8

Definition at line 419 of file parser.c.

◆ yytype_uint16

typedef unsigned short int yytype_uint16

Definition at line 425 of file parser.c.

◆ yytype_uint8

typedef unsigned char yytype_uint8

Definition at line 413 of file parser.c.

Enumeration Type Documentation

◆ yytokentype

Enumerator
DEC_CMD 
OCT_CMD 
HEX_CMD 
BIN_CMD 
DISPLAY_PREFS_CMD 
RADIAN_CMD 
REMEMBER_CMD 
LISTVAR_CMD 
STORE_CMD 
CMOD_CMD 
PRINT_HELP_CMD 
PREFIX_CMD 
INT_CMD 
VERBOSE_CMD 
DELIM_CMD 
ASSERT_CMD 
ENG_CMD 
HLIMIT_CMD 
ROUNDING_INDICATION_CMD 
PRECISION_CMD 
BITS_CMD 
BASE_CMD 
GUARD_CMD 
CONVERT_CMD 
EOLN 
OPEN_PARENTHESES 
CLOSE_PARENTHESES 
OPEN_BRACE 
CLOSE_BRACE 
OPEN_BRACKET 
CLOSE_BRACKET 
WPLUS 
WMINUS 
WMULT 
WDIV 
WMOD 
EQUALS_SIGN 
WPOW 
WEXP 
WSQR 
WOR 
WAND 
WEQUAL 
WNEQUAL 
WGT 
WLT 
WGEQ 
WLEQ 
WLSHFT 
WRSHFT 
WBOR 
WBAND 
WBXOR 
WBNOT 
WNOT 
WLOG 
WLN 
WROUND 
WABS 
WSQRT 
WCEIL 
WFLOOR 
WCBRT 
WLOGTWO 
WBANG 
WSIN 
WCOS 
WTAN 
WASIN 
WACOS 
WATAN 
WSINH 
WCOSH 
WTANH 
WASINH 
WACOSH 
WATANH 
WCOT 
WACOT 
WCOTH 
WACOTH 
WRAND 
WIRAND 
WFACT 
WCOMP 
WSEC 
WCSC 
WASEC 
WACSC 
WSECH 
WCSCH 
WASECH 
WACSCH 
WEINT 
WGAMMA 
WLNGAMMA 
WZETA 
WSINC 
NUMBER 
VARIABLE 
STRING 
OPEN_CMD 
SAVE_CMD 
ASSIGNMENT 
IDSEP_CMD 
DSEP_CMD 
ITSEP_CMD 
TSEP_CMD 
WNEG 
DEC_CMD 
OCT_CMD 
HEX_CMD 
BIN_CMD 
DISPLAY_PREFS_CMD 
RADIAN_CMD 
REMEMBER_CMD 
LISTVAR_CMD 
STORE_CMD 
CMOD_CMD 
PRINT_HELP_CMD 
PREFIX_CMD 
INT_CMD 
VERBOSE_CMD 
DELIM_CMD 
ASSERT_CMD 
ENG_CMD 
HLIMIT_CMD 
ROUNDING_INDICATION_CMD 
PRECISION_CMD 
BITS_CMD 
BASE_CMD 
GUARD_CMD 
CONVERT_CMD 
EOLN 
OPEN_PARENTHESES 
CLOSE_PARENTHESES 
OPEN_BRACE 
CLOSE_BRACE 
OPEN_BRACKET 
CLOSE_BRACKET 
WPLUS 
WMINUS 
WMULT 
WDIV 
WMOD 
EQUALS_SIGN 
WPOW 
WEXP 
WSQR 
WOR 
WAND 
WEQUAL 
WNEQUAL 
WGT 
WLT 
WGEQ 
WLEQ 
WLSHFT 
WRSHFT 
WBOR 
WBAND 
WBXOR 
WBNOT 
WNOT 
WLOG 
WLN 
WROUND 
WABS 
WSQRT 
WCEIL 
WFLOOR 
WCBRT 
WLOGTWO 
WBANG 
WSIN 
WCOS 
WTAN 
WASIN 
WACOS 
WATAN 
WSINH 
WCOSH 
WTANH 
WASINH 
WACOSH 
WATANH 
WCOT 
WACOT 
WCOTH 
WACOTH 
WRAND 
WIRAND 
WFACT 
WCOMP 
WSEC 
WCSC 
WASEC 
WACSC 
WSECH 
WCSCH 
WASECH 
WACSCH 
WEINT 
WGAMMA 
WLNGAMMA 
WZETA 
WSINC 
NUMBER 
VARIABLE 
STRING 
OPEN_CMD 
SAVE_CMD 
ASSIGNMENT 
IDSEP_CMD 
DSEP_CMD 
ITSEP_CMD 
TSEP_CMD 
WNEG 

Definition at line 149 of file parser.c.

Function Documentation

◆ free()

◆ malloc()

◆ yy_reduce_print()

static void yy_reduce_print ( yytype_int16 yyssp,
YYSTYPE yyvsp,
int  yyrule 
)
static

Definition at line 1254 of file parser.c.

References yy_symbol_print(), YYFPRINTF, yyr2, yyrline, and yystos.

◆ yy_stack_print()

static void yy_stack_print ( yytype_int16 yybottom,
yytype_int16 yytop 
)
static

Definition at line 1231 of file parser.c.

References YYFPRINTF.

◆ yy_symbol_print()

static void yy_symbol_print ( FILE *  yyoutput,
int  yytype,
YYSTYPE const *const  yyvaluep 
)
static

Definition at line 1216 of file parser.c.

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

Referenced by yy_reduce_print().

◆ yy_symbol_value_print()

static void yy_symbol_value_print ( FILE *  yyoutput,
int  yytype,
YYSTYPE const *const  yyvaluep 
)
static

Definition at line 1197 of file parser.c.

References YYNTOKENS, and YYUSE.

Referenced by yy_symbol_print().

◆ yydestruct()

static void yydestruct ( const char *  yymsg,
int  yytype,
YYSTYPE yyvaluep 
)
static

◆ yyerror()

int yyerror ( char *  error_string,
  ... 
)

Definition at line 3119 of file parser.c.

References report_error(), and synerrors.

Referenced by yyparse().

◆ yylex()

int yylex ( void  )

The main scanner function which does all the work.

Definition at line 1942 of file scanner.c.

References ASSERT_CMD, ASSIGNMENT, BASE_CMD, BIN_CMD, BITS_CMD, CLOSE_BRACE, CLOSE_BRACKET, CLOSE_PARENTHESES, CMOD_CMD, conf, CONVERT_CMD, count_digits(), DEC_CMD, _conf::dec_delimiter, DEFAULT_BASE, DELIM_CMD, DISPLAY_PREFS_CMD, Dprintf, DSEP_CMD, e, ECHO, ENG_CMD, EOB_ACT_CONTINUE_SCAN, EOB_ACT_END_OF_FILE, EOB_ACT_LAST_MATCH, EOLN, EQUALS_SIGN, explain(), GUARD_CMD, HEX_CMD, HLIMIT_CMD, IDSEP_CMD, INITIAL, INT_CMD, isconst(), isfunc(), ITSEP_CMD, line_is_a_command, LISTVAR_CMD, NO_ROUNDING_INDICATION, num_const_catalan(), num_const_euler(), num_const_pi(), num_free(), num_init(), num_init_set_d(), num_init_set_str(), num_init_set_ui(), num_mul(), num_mul_ui(), num_out_str(), num_random(), num_rint(), num_set_d(), num_set_inf, num_set_nan(), Number, NUMBER, OCT_CMD, OPEN_BRACE, OPEN_BRACKET, OPEN_CMD, OPEN_PARENTHESES, parse_yesno(), POS_CHAR, POS_STR, PRECISION_CMD, PREFIX_CMD, PRINT_HELP_CMD, RADIAN_CMD, REMEMBER_CMD, report_error(), ROUNDING_INDICATION_CMD, SAVE_CMD, scanerror, SIG_FIG_ROUNDING_INDICATION, sig_figs, SIMPLE_ROUNDING_INDICATION, STORE_CMD, strchr, STRING, strstrip(), _conf::thou_delimiter, TSEP_CMD, UINT32_MAX, VARIABLE, VERBOSE_CMD, W_ALPHA_PARTICLE_MASS, W_ATOMIC_MASS, W_AVOGADROS_CONSTANT, W_BOHR_MAGNETON, W_BOHR_RADIUS, W_BOLTZMANN_CONSTANT, W_CONDUCTANCE_QUANTUM, W_COULOMB_CONSTANT, W_DEUTERON_MASS, W_E, W_ELECTRON_MASS, W_ELECTRON_RADIUS, W_ELECTRON_VOLT, W_ELEMENTARY_CHARGE, W_FARADAY_CONSTANT, W_FERMI_COUPLING_CONSTANT, W_FINE_STRUCTURE, W_FIRST_RADIATION_CONSTANT, W_GRAVITATIONAL_ACCELLERATION, W_GRAVITATIONAL_CONSTANT, W_HARTREE_ENERGY, W_HELION_MASS, W_IMPEDANCE_OF_VACUUM, W_JOSEPHSON_CONSTANT, W_LOSCHMIDT_CONSTANT, W_MAGNETIC_FLUX_QUANTUM, W_MOLAR_GAS_CONSTANT, W_MOLAR_VOLUME_OF_IDEAL_GAS, W_MUON_MASS, W_NEUTRON_MASS, W_NUCLEAR_MAGNETON, W_PERMITTIVITY_OF_FREE_SPACE, W_PLANCK_CONSTANT, W_PROTON_MASS, W_RYDBERG_CONSTANT, W_SECOND_RADIATION_CONSTANT, W_SPEED_OF_LIGHT, W_STEFAN_BOLTZMANN, W_TAU_MASS, W_VON_KLITZING_CONSTANT, W_WIEN_DISPLACEMENT, WABS, WACOS, WACOSH, WACOT, WACOTH, WACSC, WACSCH, WAND, WASEC, WASECH, WASIN, WASINH, WATAN, WATANH, WBAND, WBANG, WBNOT, WBOR, WBXOR, WCBRT, WCEIL, WCOMP, WCOS, WCOSH, WCOT, WCOTH, WCSC, WCSCH, WDIV, WEINT, WEQUAL, WEXP, WFACT, WFLOOR, WGAMMA, WGEQ, WGT, WIRAND, WLEQ, WLN, WLNGAMMA, WLOG, WLOGTWO, WLSHFT, WLT, WMINUS, WMOD, WMULT, WNEQUAL, WNOT, WOR, WPLUS, WPOW, WRAND, WROUND, WRSHFT, WSEC, WSECH, WSIN, WSINC, WSINH, WSQR, WSQRT, WTAN, WTANH, WZETA, yy_accept, yy_base, YY_BREAK, YY_BUF_SIZE, YY_BUFFER_NEW, YY_BUFFER_NORMAL, yy_c_buf_p, yy_chk, yy_create_buffer(), YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yy_def, yy_did_buffer_switch_on_eof, YY_DO_BEFORE_ACTION, yy_ec, YY_END_OF_BUFFER, YY_FATAL_ERROR, yy_get_next_buffer(), yy_get_previous_state(), yy_hold_char, yy_init, yy_last_accepting_cpos, yy_last_accepting_state, yy_load_buffer_state(), yy_meta, YY_MORE_ADJ, yy_n_chars, YY_NEW_FILE, yy_nxt, YY_RESTORE_YY_MORE_OFFSET, YY_RULE_SETUP, YY_SC_TO_UI, YY_START, yy_start, YY_STATE_EOF, yy_try_NUL_trans(), yydebug, yyensure_buffer_stack(), yyin, yyleng, YYLVALAC, yyout, yyterminate, yytext, yytext_ptr, and yywrap.

Referenced by yyparse().

◆ yyparse()

int yyparse ( void  )

Definition at line 1563 of file parser.c.

References always, automatic, BINARY_FORMAT, _conf::c_style_mod, YYSTYPE::cmd, column, compute, conf, _conf::dec_delimiter, DECIMAL_FORMAT, display_interactive_help(), display_output_format(), display_prefs(), display_status(), display_val(), _conf::engineering, free(), YYSTYPE::function, HEXADECIMAL_FORMAT, _conf::history_limit, _conf::history_limit_len, identify_units(), _conf::in_dec_delimiter, _conf::in_thou_delimiter, YYSTYPE::integer, isatty(), last_answer, line_is_a_command, lines, malloc(), never, NO_ROUNDING_INDICATION, nothing, num_factorial(), num_free(), num_get_ui(), num_init(), num_init_set(), num_init_set_ui(), num_mul(), num_mul_si(), num_pow(), NUM_PREC_MAX, NUM_PREC_MIN, num_set(), num_set_default_prec, num_sqr(), num_to_str_complex(), YYSTYPE::number, OCTAL_FORMAT, open_file, _conf::output_format, _conf::precision, _conf::precision_guard, pretty_answer, _conf::print_commas, _conf::print_ints, _conf::print_prefixes, printvariables(), putexp(), putval(), redisplay, _conf::remember_errors, report_error(), _conf::rounding_indication, saveState(), scanerror, set_prettyanswer(), simple_exp(), SIMPLE_ROUNDING_INDICATION, standard_output, storeVar(), synerrors, _conf::thou_delimiter, uber_conversion(), uber_function(), unit_id(), _conf::use_radians, YYSTYPE::variable, _conf::verbose, wabs, wacos, wacosh, wacot, wacoth, wacsc, wacsch, wand, wasec, wasech, wasin, wasinh, watan, watanh, wband, wbnot, wbor, wbxor, wcbrt, wceil, wcomp, wcos, wcosh, wcot, wcoth, wcsc, wcsch, wdiv, weint, wequal, wexp, wfact, wfloor, wgamma, wgeq, wgt, wirand, wleq, wln, wlngamma, wlog, wlogtwo, wlshft, wlt, wminus, wmod, wmult, wnequal, wnot, wor, wplus, wrand, wround, wrshft, wsec, wsech, wsin, wsinc, wsinh, wsqrt, wtan, wtanh, wzeta, YY_, YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN, YY_IGNORE_MAYBE_UNINITIALIZED_END, YY_REDUCE_PRINT, YY_STACK_PRINT, YY_SYMBOL_PRINT, YYABORT, YYACCEPT, yychar, yycheck, yydefact, yydefgoto, yydestruct(), YYDPRINTF, YYEMPTY, YYEOF, yyerror(), YYFINAL, YYINITDEPTH, YYLAST, yylex(), yylval, YYMAXDEPTH, yynerrs, YYNTOKENS, yypact, yypact_value_is_default, yypgoto, YYPOPSTACK, yyr1, yyr2, YYSIZE_T, yyalloc::yyss_alloc, YYSTACK_ALLOC, YYSTACK_BYTES, YYSTACK_FREE, YYSTACK_RELOCATE, yystos, yytable, yytable_value_is_error, YYTERROR, YYTRANSLATE, and yyalloc::yyvs_alloc.

Referenced by parseme().

Variable Documentation

◆ errloc

int errloc = -1

Definition at line 112 of file parser.c.

Referenced by display_and_clear_errstring(), main(), and report_error().

◆ errstring

◆ lines

int lines = 1

Definition at line 108 of file parser.c.

Referenced by main(), report_error(), and yyparse().

◆ scanerror

short scanerror = 0

◆ show_line_numbers

int show_line_numbers = 0

Definition at line 113 of file parser.c.

Referenced by display_and_clear_errstring(), main(), parseme(), and report_error().

◆ synerrors

int synerrors = 0

Definition at line 109 of file parser.c.

Referenced by parseme(), yyerror(), and yyparse().

◆ yychar

int yychar

Definition at line 1550 of file parser.c.

Referenced by yyparse().

◆ yycheck

const yytype_int16 yycheck[]
static

Definition at line 958 of file parser.c.

Referenced by yyparse().

◆ yydebug

int yydebug

Definition at line 1281 of file parser.c.

Referenced by main(), and yylex().

◆ yydefact

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

Definition at line 815 of file parser.c.

Referenced by yyparse().

◆ yydefgoto

const yytype_int16 yydefgoto[]
static
Initial value:
=
{
-1, 85, 86, 87, 88, 89, 148, 90, 91, 92,
93, 94, 95, 140, 96, 97, 98
}

Definition at line 845 of file parser.c.

Referenced by yyparse().

◆ yylval

YYSTYPE yylval

Definition at line 1553 of file parser.c.

Referenced by yyparse().

◆ yynerrs

int yynerrs

Definition at line 1555 of file parser.c.

Referenced by yyparse().

◆ yypact

const yytype_int16 yypact[]
static
Initial value:
=
{
0, 4, -91, -91, -91, -91, -91, -91, -91, -91,
-69, -91, -91, -91, -91, -91, -91, -91, -91, -91,
-91, -91, -91, -91, -91, -91, -91, 399, 473, 547,
-91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
-91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
-91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
-91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
-91, -91, -91, -91, -91, -91, -91, -2, -91, -91,
249, -91, -91, -91, -91, 39, -91, 111, -91, 4,
4, 845, 8, -91, 695, -91, -91, -91, 621, -91,
-91, -91, -91, 872, -91, 897, -91, 920, 323, -57,
768, -91, -91, -91, -91, 695, 695, 695, 695, 695,
695, 695, 695, 695, 695, 695, 695, 695, 695, 695,
695, 695, 695, -91, 769, -91, 769, 10, -91, -91,
-91, 769, -91, -91, -91, -57, 768, -91, -91, -91,
236, 236, -7, -7, -7, 620, 620, 188, 188, 188,
188, 188, 188, -7, -7, 620, 620, 942, -13, -91,
769, -91, -91, -91, 769, -91
}

Definition at line 790 of file parser.c.

Referenced by yyparse().

◆ yypgoto

const yytype_int16 yypgoto[]
static
Initial value:
=
{
-91, -91, -38, -91, 66, -91, 3, -91, 133, -91,
-91, -90, -44, 93, 130, -41, -82
}

Definition at line 838 of file parser.c.

Referenced by yyparse().

◆ yyr1

const yytype_uint8 yyr1[]
static
Initial value:
=
{
0, 112, 113, 113, 114, 114, 115, 115, 115, 115,
115, 116, 117, 117, 117, 117, 117, 117, 117, 117,
117, 117, 117, 117, 117, 117, 117, 117, 117, 117,
117, 117, 117, 117, 117, 117, 117, 117, 117, 117,
117, 117, 118, 118, 119, 119, 119, 119, 120, 120,
120, 120, 120, 120, 120, 120, 120, 120, 120, 120,
120, 120, 120, 120, 120, 120, 120, 121, 121, 121,
121, 121, 121, 121, 121, 121, 121, 121, 121, 121,
121, 121, 121, 121, 121, 121, 121, 121, 121, 121,
121, 121, 121, 121, 121, 121, 121, 121, 121, 121,
121, 121, 121, 121, 121, 121, 121, 121, 121, 121,
121, 121, 122, 122, 122, 123, 123, 123, 124, 124,
125, 125, 126, 126, 127, 127, 127, 127, 128, 128,
128, 128, 128, 128
}

Definition at line 1087 of file parser.c.

Referenced by yyparse().

◆ yyr2

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

Definition at line 1106 of file parser.c.

Referenced by yy_reduce_print(), and yyparse().

◆ yyrline

const yytype_uint16 yyrline[]
static
Initial value:
=
{
0, 109, 109, 110, 113, 114, 117, 136, 142, 159,
169, 183, 186, 190, 194, 198, 202, 211, 221, 231,
241, 252, 257, 262, 268, 272, 276, 284, 292, 302,
306, 323, 335, 340, 345, 349, 367, 375, 385, 408,
419, 429, 437, 440, 445, 468, 490, 498, 508, 509,
510, 511, 512, 513, 514, 515, 516, 517, 518, 519,
520, 521, 522, 523, 524, 525, 526, 529, 530, 531,
532, 533, 534, 535, 536, 537, 538, 539, 540, 541,
542, 543, 544, 545, 546, 547, 548, 549, 550, 551,
552, 553, 554, 555, 556, 557, 558, 559, 560, 561,
562, 563, 564, 565, 566, 567, 568, 569, 570, 571,
572, 573, 576, 577, 578, 581, 582, 583, 586, 587,
594, 599, 602, 606, 615, 617, 619, 621, 624, 626,
627, 633, 634, 640
}

Definition at line 710 of file parser.c.

Referenced by yy_reduce_print().

◆ yystos

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

Definition at line 1064 of file parser.c.

Referenced by yy_reduce_print(), and yyparse().

◆ yytable

const yytype_int16 yytable[]
static

Definition at line 854 of file parser.c.

Referenced by yyparse().

◆ yytname

const char* const yytname[]
static
Initial value:
=
{
"$end", "error", "$undefined", "DEC_CMD", "OCT_CMD", "HEX_CMD",
"BIN_CMD", "DISPLAY_PREFS_CMD", "RADIAN_CMD", "REMEMBER_CMD",
"LISTVAR_CMD", "STORE_CMD", "CMOD_CMD", "PRINT_HELP_CMD", "PREFIX_CMD",
"INT_CMD", "VERBOSE_CMD", "DELIM_CMD", "ASSERT_CMD", "ENG_CMD",
"HLIMIT_CMD", "ROUNDING_INDICATION_CMD", "PRECISION_CMD", "BITS_CMD",
"BASE_CMD", "GUARD_CMD", "CONVERT_CMD", "EOLN", "OPEN_PARENTHESES",
"CLOSE_PARENTHESES", "OPEN_BRACE", "CLOSE_BRACE", "OPEN_BRACKET",
"CLOSE_BRACKET", "WPLUS", "WMINUS", "WMULT", "WDIV", "WMOD",
"EQUALS_SIGN", "WPOW", "WEXP", "WSQR", "WOR", "WAND", "WEQUAL",
"WNEQUAL", "WGT", "WLT", "WGEQ", "WLEQ", "WLSHFT", "WRSHFT", "WBOR",
"WBAND", "WBXOR", "WBNOT", "WNOT", "WLOG", "WLN", "WROUND", "WABS",
"WSQRT", "WCEIL", "WFLOOR", "WCBRT", "WLOGTWO", "WBANG", "WSIN", "WCOS",
"WTAN", "WASIN", "WACOS", "WATAN", "WSINH", "WCOSH", "WTANH", "WASINH",
"WACOSH", "WATANH", "WCOT", "WACOT", "WCOTH", "WACOTH", "WRAND",
"WIRAND", "WFACT", "WCOMP", "WSEC", "WCSC", "WASEC", "WACSC", "WSECH",
"WCSCH", "WASECH", "WACSCH", "WEINT", "WGAMMA", "WLNGAMMA", "WZETA",
"WSINC", "NUMBER", "VARIABLE", "STRING", "OPEN_CMD", "SAVE_CMD",
"ASSIGNMENT", "IDSEP_CMD", "DSEP_CMD", "ITSEP_CMD", "TSEP_CMD", "WNEG",
"$accept", "input", "lines", "oneline", "eoln", "command",
"optionalstring", "assignment", "exp", "func", "nullexp", "sign",
"exp_l2", "oval", "exp_l3", "parenthated", "capsule", 0
}

Definition at line 732 of file parser.c.

Referenced by yy_symbol_print().

◆ yytranslate

const yytype_uint8 yytranslate[]
static

Definition at line 667 of file parser.c.

yychar
int yychar
Definition: parser.c:1550
YYEMPTY
#define YYEMPTY
Definition: parser.c:1127
yydebug
int yydebug
Definition: parser.c:1281
YYSTYPE
union YYSTYPE YYSTYPE
Definition: parser.c:375
YY_
#define YY_(Msgid)
Definition: parser.c:457
YYSTACK_GAP_MAXIMUM
#define YYSTACK_GAP_MAXIMUM
Definition: parser.c:595
yytype_int16
short int yytype_int16
Definition: parser.c:431