/* ex: set ro ft=c:
 * !!!!!!!   DO NOT EDIT THIS FILE   !!!!!!!
 *
 * This file is generated automatically from 'compilers/imcc/imcc.y'
 * by tools/build/fixup_gen_file.pl.
 *
 * Any changes made here will be lost!
 *
 */
/* HEADERIZER HFILE: none */
/* HEADERIZER STOP */
/* A Bison parser, made by GNU Bison 2.3.  */

/* Skeleton implementation for Bison's Yacc-like parsers in C

   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
   Free Software Foundation, Inc.

   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 2, or (at your option)
   any later version.

   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program; if not, write to the Free Software
   Foundation, Inc., 51 Franklin Street, Fifth Floor,
   Boston, MA 02110-1301, USA.  */

/* As a special exception, you may create a larger work that contains
   part or all of the Bison parser skeleton and distribute that work
   under terms of your choice, so long as that work isn't itself a
   parser generator using the skeleton or a modified version thereof
   as a parser skeleton.  Alternatively, if you modify or redistribute
   the parser skeleton itself, you may (at your option) remove this
   special exception, which will cause the skeleton and the resulting
   Bison output files to be licensed under the GNU General Public
   License without this special exception.

   This special exception was added by the Free Software Foundation in
   version 2.2 of Bison.  */

/* C LALR(1) parser skeleton written by Richard Stallman, by
   simplifying the original so-called "semantic" parser.  */

/* All symbols defined below should begin with yy or YY, to avoid
   infringing on user name space.  This should be done even for local
   variables, as they might otherwise be expanded by user macros.
   There are some unavoidable exceptions within include files to
   define necessary library symbols; they are noted "INFRINGES ON
   USER NAME SPACE" below.  */

/* Identify Bison output.  */
#define YYBISON 1

/* Bison version.  */
#define YYBISON_VERSION "2.3"

/* Skeleton name.  */
#define YYSKELETON_NAME "yacc.c"

/* Pure parsers.  */
#define YYPURE 1

/* Using locations.  */
#define YYLSP_NEEDED 0



/* Tokens.  */
#ifndef YYTOKENTYPE
# define YYTOKENTYPE
   /* Put the tokens into the symbol table, so that GDB and other debuggers
      know about them.  */
   enum yytokentype {
     LOW_PREC = 258,
     PARAM = 259,
     HLL = 260,
     HLL_MAP = 261,
     TK_LINE = 262,
     TK_FILE = 263,
     GOTO = 264,
     ARG = 265,
     IF = 266,
     UNLESS = 267,
     PNULL = 268,
     SET_RETURN = 269,
     SET_YIELD = 270,
     ADV_FLAT = 271,
     ADV_SLURPY = 272,
     ADV_OPTIONAL = 273,
     ADV_OPT_FLAG = 274,
     ADV_NAMED = 275,
     ADV_ARROW = 276,
     NEW = 277,
     ADV_INVOCANT = 278,
     NAMESPACE = 279,
     DOT_METHOD = 280,
     SUB = 281,
     SYM = 282,
     LOCAL = 283,
     LEXICAL = 284,
     CONST = 285,
     ANNOTATE = 286,
     INC = 287,
     DEC = 288,
     GLOBAL_CONST = 289,
     PLUS_ASSIGN = 290,
     MINUS_ASSIGN = 291,
     MUL_ASSIGN = 292,
     DIV_ASSIGN = 293,
     CONCAT_ASSIGN = 294,
     BAND_ASSIGN = 295,
     BOR_ASSIGN = 296,
     BXOR_ASSIGN = 297,
     FDIV = 298,
     FDIV_ASSIGN = 299,
     MOD_ASSIGN = 300,
     SHR_ASSIGN = 301,
     SHL_ASSIGN = 302,
     SHR_U_ASSIGN = 303,
     SHIFT_LEFT = 304,
     SHIFT_RIGHT = 305,
     INTV = 306,
     FLOATV = 307,
     STRINGV = 308,
     PMCV = 309,
     LOG_XOR = 310,
     RELOP_EQ = 311,
     RELOP_NE = 312,
     RELOP_GT = 313,
     RELOP_GTE = 314,
     RELOP_LT = 315,
     RELOP_LTE = 316,
     RESULT = 317,
     RETURN = 318,
     TAILCALL = 319,
     YIELDT = 320,
     GET_RESULTS = 321,
     POW = 322,
     SHIFT_RIGHT_U = 323,
     LOG_AND = 324,
     LOG_OR = 325,
     COMMA = 326,
     ESUB = 327,
     DOTDOT = 328,
     PCC_BEGIN = 329,
     PCC_END = 330,
     PCC_CALL = 331,
     PCC_SUB = 332,
     PCC_BEGIN_RETURN = 333,
     PCC_END_RETURN = 334,
     PCC_BEGIN_YIELD = 335,
     PCC_END_YIELD = 336,
     NCI_CALL = 337,
     METH_CALL = 338,
     INVOCANT = 339,
     MAIN = 340,
     LOAD = 341,
     INIT = 342,
     IMMEDIATE = 343,
     POSTCOMP = 344,
     METHOD = 345,
     ANON = 346,
     OUTER = 347,
     NEED_LEX = 348,
     MULTI = 349,
     VTABLE_METHOD = 350,
     LOADLIB = 351,
     SUB_INSTANCE_OF = 352,
     SUBID = 353,
     NS_ENTRY = 354,
     UNIQUE_REG = 355,
     LABEL = 356,
     EMIT = 357,
     EOM = 358,
     IREG = 359,
     NREG = 360,
     SREG = 361,
     PREG = 362,
     IDENTIFIER = 363,
     REG = 364,
     MACRO = 365,
     ENDM = 366,
     STRINGC = 367,
     INTC = 368,
     FLOATC = 369,
     USTRINGC = 370,
     PARROT_OP = 371,
     VAR = 372,
     LINECOMMENT = 373,
     FILECOMMENT = 374,
     DOT = 375,
     CONCAT = 376
   };
#endif
/* Tokens.  */
#define LOW_PREC 258
#define PARAM 259
#define HLL 260
#define HLL_MAP 261
#define TK_LINE 262
#define TK_FILE 263
#define GOTO 264
#define ARG 265
#define IF 266
#define UNLESS 267
#define PNULL 268
#define SET_RETURN 269
#define SET_YIELD 270
#define ADV_FLAT 271
#define ADV_SLURPY 272
#define ADV_OPTIONAL 273
#define ADV_OPT_FLAG 274
#define ADV_NAMED 275
#define ADV_ARROW 276
#define NEW 277
#define ADV_INVOCANT 278
#define NAMESPACE 279
#define DOT_METHOD 280
#define SUB 281
#define SYM 282
#define LOCAL 283
#define LEXICAL 284
#define CONST 285
#define ANNOTATE 286
#define INC 287
#define DEC 288
#define GLOBAL_CONST 289
#define PLUS_ASSIGN 290
#define MINUS_ASSIGN 291
#define MUL_ASSIGN 292
#define DIV_ASSIGN 293
#define CONCAT_ASSIGN 294
#define BAND_ASSIGN 295
#define BOR_ASSIGN 296
#define BXOR_ASSIGN 297
#define FDIV 298
#define FDIV_ASSIGN 299
#define MOD_ASSIGN 300
#define SHR_ASSIGN 301
#define SHL_ASSIGN 302
#define SHR_U_ASSIGN 303
#define SHIFT_LEFT 304
#define SHIFT_RIGHT 305
#define INTV 306
#define FLOATV 307
#define STRINGV 308
#define PMCV 309
#define LOG_XOR 310
#define RELOP_EQ 311
#define RELOP_NE 312
#define RELOP_GT 313
#define RELOP_GTE 314
#define RELOP_LT 315
#define RELOP_LTE 316
#define RESULT 317
#define RETURN 318
#define TAILCALL 319
#define YIELDT 320
#define GET_RESULTS 321
#define POW 322
#define SHIFT_RIGHT_U 323
#define LOG_AND 324
#define LOG_OR 325
#define COMMA 326
#define ESUB 327
#define DOTDOT 328
#define PCC_BEGIN 329
#define PCC_END 330
#define PCC_CALL 331
#define PCC_SUB 332
#define PCC_BEGIN_RETURN 333
#define PCC_END_RETURN 334
#define PCC_BEGIN_YIELD 335
#define PCC_END_YIELD 336
#define NCI_CALL 337
#define METH_CALL 338
#define INVOCANT 339
#define MAIN 340
#define LOAD 341
#define INIT 342
#define IMMEDIATE 343
#define POSTCOMP 344
#define METHOD 345
#define ANON 346
#define OUTER 347
#define NEED_LEX 348
#define MULTI 349
#define VTABLE_METHOD 350
#define LOADLIB 351
#define SUB_INSTANCE_OF 352
#define SUBID 353
#define NS_ENTRY 354
#define UNIQUE_REG 355
#define LABEL 356
#define EMIT 357
#define EOM 358
#define IREG 359
#define NREG 360
#define SREG 361
#define PREG 362
#define IDENTIFIER 363
#define REG 364
#define MACRO 365
#define ENDM 366
#define STRINGC 367
#define INTC 368
#define FLOATC 369
#define USTRINGC 370
#define PARROT_OP 371
#define VAR 372
#define LINECOMMENT 373
#define FILECOMMENT 374
#define DOT 375
#define CONCAT 376




/* Copy the first part of user declarations.  */
#line 1 "compilers/imcc/imcc.y"

/*
 * imcc.y
 *
 * Intermediate Code Compiler for Parrot.
 *
 * Copyright (C) 2002 Melvin Smith <melvin.smith@mindspring.com>
 * Copyright (C) 2002-2008, The Perl Foundation.
 *
 * Grammar of the PIR language parser.
 *
 * $Id: /mirror/trunk/compilers/imcc/imcparser.c 35384 2009-01-10T21:25:07.761735Z Whiteknight  $
 *
 */

#include <string.h>
#include <stdio.h>
#include <stdlib.h>

#define _PARSER
#define PARSER_MAIN
#include "imc.h"
#include "parrot/dynext.h"
#include "pbc.h"
#include "parser.h"
#include "optimizer.h"

/* prevent declarations of malloc() and free() in the generated parser. */
#define YYMALLOC
#define YYFREE

#ifndef YYENABLE_NLS
#  define YYENABLE_NLS 0
#endif

#ifndef YYLTYPE_IS_TRIVIAL
#  define YYLTYPE_IS_TRIVIAL 0
#endif

/* HEADERIZER HFILE: compilers/imcc/imc.h */

/* HEADERIZER BEGIN: static */
/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */

static void add_pcc_named_arg(PARROT_INTERP,
    ARGMOD(SymReg *cur_call),
    ARGIN(const char *name),
    ARGIN(SymReg *value))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        FUNC_MODIFIES(*cur_call);

static void add_pcc_named_param(PARROT_INTERP,
    ARGMOD(SymReg *cur_call),
    ARGIN(const char *name),
    ARGIN(SymReg *value))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        FUNC_MODIFIES(*cur_call);

static void add_pcc_named_result(PARROT_INTERP,
    ARGMOD(SymReg *cur_call),
    ARGIN(const char *name),
    ARGIN(SymReg *value))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        FUNC_MODIFIES(*cur_call);

static void add_pcc_named_return(PARROT_INTERP,
    ARGMOD(SymReg *cur_call),
    ARGIN(const char *name),
    ARGIN(SymReg *value))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        FUNC_MODIFIES(*cur_call);

static void adv_named_set(PARROT_INTERP, ARGIN(char *name))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2);

static void begin_return_or_yield(PARROT_INTERP, int yield)
        __attribute__nonnull__(1);

static void clear_state(PARROT_INTERP)
        __attribute__nonnull__(1);

static void do_loadlib(PARROT_INTERP, ARGIN(const char *lib))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2);

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction* func_ins(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(SymReg *lhs),
    ARGIN(const char *op),
    ARGMOD(SymReg **r),
    int n,
    int keyv,
    int emit)
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        __attribute__nonnull__(5)
        FUNC_MODIFIES(*unit)
        FUNC_MODIFIES(*r);

PARROT_CAN_RETURN_NULL
static Instruction * iINDEXFETCH(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(SymReg *r0),
    ARGIN(SymReg *r1),
    ARGIN(SymReg *r2))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        __attribute__nonnull__(5)
        FUNC_MODIFIES(*unit);

PARROT_CAN_RETURN_NULL
static Instruction * iINDEXSET(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(SymReg *r0),
    ARGIN(SymReg *r1),
    ARGIN(SymReg *r2))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        __attribute__nonnull__(5)
        FUNC_MODIFIES(*unit);

PARROT_CANNOT_RETURN_NULL
static Instruction * iLABEL(PARROT_INTERP,
    ARGMOD_NULLOK(IMC_Unit *unit),
    ARGMOD(SymReg *r0))
        __attribute__nonnull__(1)
        __attribute__nonnull__(3)
        FUNC_MODIFIES(*unit)
        FUNC_MODIFIES(*r0);

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static const char * inv_op(ARGIN(const char *op))
        __attribute__nonnull__(1);

PARROT_CANNOT_RETURN_NULL
static Instruction * iSUBROUTINE(PARROT_INTERP,
    ARGMOD_NULLOK(IMC_Unit *unit),
    ARGMOD(SymReg *r))
        __attribute__nonnull__(1)
        __attribute__nonnull__(3)
        FUNC_MODIFIES(*unit)
        FUNC_MODIFIES(*r);

PARROT_IGNORABLE_RESULT
PARROT_CAN_RETURN_NULL
static Instruction * MK_I(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(const char *fmt),
    int n,
    ...)
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        FUNC_MODIFIES(*unit);

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction* mk_pmc_const(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(const char *type),
    ARGMOD(SymReg *left),
    ARGIN(const char *constant))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        __attribute__nonnull__(5)
        FUNC_MODIFIES(*unit)
        FUNC_MODIFIES(*left);

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction* mk_pmc_const_named(PARROT_INTERP,
    ARGMOD(IMC_Unit *unit),
    ARGIN(const char *name),
    ARGMOD(SymReg *left),
    ARGIN(const char *constant))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        __attribute__nonnull__(4)
        __attribute__nonnull__(5)
        FUNC_MODIFIES(*unit)
        FUNC_MODIFIES(*left);

PARROT_CANNOT_RETURN_NULL
static SymReg * mk_sub_address_fromc(PARROT_INTERP, ARGIN(const char *name))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2);

PARROT_CANNOT_RETURN_NULL
static SymReg * mk_sub_address_u(PARROT_INTERP, ARGIN(const char *name))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2);

static void set_lexical(PARROT_INTERP,
    ARGMOD(SymReg *r),
    ARGIN(const char *name))
        __attribute__nonnull__(1)
        __attribute__nonnull__(2)
        __attribute__nonnull__(3)
        FUNC_MODIFIES(*r);

#define ASSERT_ARGS_add_pcc_named_arg __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(cur_call) \
    || PARROT_ASSERT_ARG(name) \
    || PARROT_ASSERT_ARG(value)
#define ASSERT_ARGS_add_pcc_named_param __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(cur_call) \
    || PARROT_ASSERT_ARG(name) \
    || PARROT_ASSERT_ARG(value)
#define ASSERT_ARGS_add_pcc_named_result __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(cur_call) \
    || PARROT_ASSERT_ARG(name) \
    || PARROT_ASSERT_ARG(value)
#define ASSERT_ARGS_add_pcc_named_return __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(cur_call) \
    || PARROT_ASSERT_ARG(name) \
    || PARROT_ASSERT_ARG(value)
#define ASSERT_ARGS_adv_named_set __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(name)
#define ASSERT_ARGS_begin_return_or_yield __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp)
#define ASSERT_ARGS_clear_state __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp)
#define ASSERT_ARGS_do_loadlib __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(lib)
#define ASSERT_ARGS_func_ins __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(lhs) \
    || PARROT_ASSERT_ARG(op) \
    || PARROT_ASSERT_ARG(r)
#define ASSERT_ARGS_iINDEXFETCH __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(r0) \
    || PARROT_ASSERT_ARG(r1) \
    || PARROT_ASSERT_ARG(r2)
#define ASSERT_ARGS_iINDEXSET __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(r0) \
    || PARROT_ASSERT_ARG(r1) \
    || PARROT_ASSERT_ARG(r2)
#define ASSERT_ARGS_iLABEL __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(r0)
#define ASSERT_ARGS_inv_op __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(op)
#define ASSERT_ARGS_iSUBROUTINE __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(r)
#define ASSERT_ARGS_MK_I __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(fmt)
#define ASSERT_ARGS_mk_pmc_const __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(type) \
    || PARROT_ASSERT_ARG(left) \
    || PARROT_ASSERT_ARG(constant)
#define ASSERT_ARGS_mk_pmc_const_named __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(unit) \
    || PARROT_ASSERT_ARG(name) \
    || PARROT_ASSERT_ARG(left) \
    || PARROT_ASSERT_ARG(constant)
#define ASSERT_ARGS_mk_sub_address_fromc __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(name)
#define ASSERT_ARGS_mk_sub_address_u __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(name)
#define ASSERT_ARGS_set_lexical __attribute__unused__ int _ASSERT_ARGS_CHECK = \
       PARROT_ASSERT_ARG(interp) \
    || PARROT_ASSERT_ARG(r) \
    || PARROT_ASSERT_ARG(name)
/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
/* HEADERIZER END: static */


#define YYDEBUG 1
#define YYERROR_VERBOSE 1

/*
 * We use a pure parser with the interpreter as a parameter. However this still
 * doesn't make the parser reentrant, as there are too many globals around.
 */

/*
 * Choosing instructions for Parrot is pretty easy since many are
 * polymorphic.
 */


/*
 * MK_I: build and emitb instruction by INS
 *
 * fmt may contain:
 *   op %s, %s # comment
 * or just
 *   op
 *
 *
 *  NOTE: Most usage of this function is with
 *        IMCC_INFO(interp)->cur_unit, but there are some
 *        exceptions. Thus, we can't easily factorize that piece of
 *        code.
 */

PARROT_IGNORABLE_RESULT
PARROT_CAN_RETURN_NULL
static Instruction *
MK_I(PARROT_INTERP, ARGMOD(IMC_Unit *unit), ARGIN(const char *fmt), int n, ...)
{
    ASSERT_ARGS(MK_I)
    char opname[64];
    char *p;
    const char *q;
    va_list ap;
    SymReg *r[IMCC_MAX_FIX_REGS];
    int i;

    for (p = opname, q = fmt; *q && *q != ' ';)
        *p++ = *q++;
    *p = 0;
    if (!*q)
        fmt = NULL;
    else
        fmt = ++q;
#ifdef OPDEBUG
    fprintf(stderr, "op '%s' format '%s' (%d)\n", opname, fmt?:"", n);
#endif
    va_start(ap, n);
    i = 0;
    for (i = 0; i < n; ++i) {
        r[i] = va_arg(ap, SymReg *);
    }
    va_end(ap);
    return INS(interp, unit, opname, fmt, r, n,
               IMCC_INFO(interp)->keyvec, 1);
}

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction*
mk_pmc_const(PARROT_INTERP, ARGMOD(IMC_Unit *unit), ARGIN(const char *type),
        ARGMOD(SymReg *left), ARGIN(const char *constant))
{
    ASSERT_ARGS(mk_pmc_const)
    const int type_enum = atoi(type);
    const int ascii = (*constant == '\'' || *constant == '"');
    SymReg *rhs;
    SymReg *r[3];
    char   *name;

    if (left->type == VTADDRESS) {      /* IDENTIFIER */
        if (IMCC_INFO(interp)->state->pasm_file) {
            IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                        "Ident as PMC constant",
                        " %s\n", left->name);
        }
        left->type = VTIDENTIFIER;
        left->set = 'P';
    }
    r[0] = left;
    if (ascii) {
        /* strip delimiters */
        name                   = str_dup(constant + 1);
        name[strlen(name) - 1] = '\0';
    }
    else {
        name = str_dup(constant);
    }

    switch (type_enum) {
        case enum_class_Sub:
        case enum_class_Coroutine:
            rhs = mk_const(interp, name, 'p');

            if (!ascii)
                rhs->type |= VT_ENCODED;

            rhs->usage    = U_FIXUP | U_SUBID_LOOKUP;;
            break;
        default:
            rhs = mk_const(interp, name, 'P');
            break;
    }

    r[1]          = rhs;
    rhs->pmc_type = type_enum;

    mem_sys_free(name);

    return INS(interp, unit, "set_p_pc", "", r, 2, 0, 1);
}

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction*
mk_pmc_const_named(PARROT_INTERP, ARGMOD(IMC_Unit *unit),
    ARGIN(const char *name), ARGMOD(SymReg *left), ARGIN(const char *constant))
{
    ASSERT_ARGS(mk_pmc_const_named)
    SymReg *rhs;
    SymReg *r[3];
    char   *const_name;
    const int ascii       = (*constant == '\'' || *constant == '"');
    char   *unquoted_name = str_dup(name + 1);
    size_t  name_length   = strlen(unquoted_name) - 1;

    unquoted_name[name_length] = '\0';

    if (left->type == VTADDRESS) {      /* IDENTIFIER */
        if (IMCC_INFO(interp)->state->pasm_file) {
            IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                        "Ident as PMC constant",
                        " %s\n", left->name);
        }
        left->type = VTIDENTIFIER;
        left->set = 'P';
    }
    r[0] = left;
    if (ascii) {
        /* strip delimiters */
        const_name                         = str_dup(constant + 1);
        const_name[strlen(const_name) - 1] = '\0';
    }
    else {
        const_name = str_dup(constant);
    }

    if ((strncmp(unquoted_name, "Sub",       name_length) == 0)
    ||  (strncmp(unquoted_name, "Coroutine", name_length) == 0)) {
        rhs = mk_const(interp, const_name, 'p');

        if (!ascii)
            rhs->type |= VT_ENCODED;

        rhs->usage    = U_FIXUP | U_SUBID_LOOKUP;
    }
    else {
        rhs = mk_const(interp, const_name, 'P');
    }

    r[1]          = rhs;
    rhs->pmc_type = pmc_type(interp,
        string_from_cstring(interp, unquoted_name, name_length));

    mem_sys_free(unquoted_name);
    mem_sys_free(const_name);

    return INS(interp, unit, "set_p_pc", "", r, 2, 0, 1);
}

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static Instruction*
func_ins(PARROT_INTERP, ARGMOD(IMC_Unit *unit), ARGIN(SymReg *lhs), ARGIN(const char *op),
         ARGMOD(SymReg **r), int n, int keyv, int emit)
{
    ASSERT_ARGS(func_ins)
    int i;
    /* shift regs up by 1 */
    for (i = n - 1; i >= 0; --i)
        r[i+1] = r[i];
    r[0] = lhs;
    /* shift keyvec */
    keyv <<= 1;
    return INS(interp, unit, op, "", r, n+1, keyv, emit);
}
/*
 * special instructions
 *
 * labels and such
 */

static void
clear_state(PARROT_INTERP)
{
    ASSERT_ARGS(clear_state)
    IMCC_INFO(interp) -> nargs = 0;
    IMCC_INFO(interp) -> keyvec = 0;
}

PARROT_CANNOT_RETURN_NULL
Instruction *
INS_LABEL(PARROT_INTERP, ARGMOD_NULLOK(IMC_Unit *unit), ARGMOD(SymReg *r0), int emit)
{
    ASSERT_ARGS(INS_LABEL)

    Instruction * const ins = _mk_instruction("", "%s:", 1, &r0, 0);
    ins->type               = ITLABEL;
    r0->first_ins           = ins;

    if (emit)
        emitb(interp, unit, ins);

    return ins;
}

PARROT_CANNOT_RETURN_NULL
static Instruction *
iLABEL(PARROT_INTERP, ARGMOD_NULLOK(IMC_Unit *unit), ARGMOD(SymReg *r0))
{
    ASSERT_ARGS(iLABEL)
    Instruction * const i = INS_LABEL(interp, unit, r0, 1);
    i->line               = IMCC_INFO(interp)->line;

    clear_state(interp);
    return i;
}

PARROT_CANNOT_RETURN_NULL
static Instruction *
iSUBROUTINE(PARROT_INTERP, ARGMOD_NULLOK(IMC_Unit *unit), ARGMOD(SymReg *r))
{
    ASSERT_ARGS(iSUBROUTINE)
    Instruction * const i = iLABEL(interp, unit, r);

    r->type    = (r->type & VT_ENCODED) ? VT_PCC_SUB|VT_ENCODED : VT_PCC_SUB;
    r->pcc_sub = mem_allocate_zeroed_typed(pcc_sub_t);

    IMCC_INFO(interp)->cur_call = r;
    i->line                     = IMCC_INFO(interp)->line;

    add_namespace(interp, unit);
    return i;
}

/*
 * substr or X = P[key]
 */
PARROT_CAN_RETURN_NULL
static Instruction *
iINDEXFETCH(PARROT_INTERP, ARGMOD(IMC_Unit *unit), ARGIN(SymReg *r0), ARGIN(SymReg *r1),
        ARGIN(SymReg *r2))
{
    ASSERT_ARGS(iINDEXFETCH)
    IMCC_INFO(interp) -> keyvec |= KEY_BIT(2);
    return MK_I(interp, unit, "set %s, %s[%s]", 3, r0, r1, r2);
}

/*
 * substr or P[key] = X
 */

PARROT_CAN_RETURN_NULL
static Instruction *
iINDEXSET(PARROT_INTERP, ARGMOD(IMC_Unit *unit), ARGIN(SymReg *r0), ARGIN(SymReg *r1),
        ARGIN(SymReg *r2))
{
    ASSERT_ARGS(iINDEXSET)
    if (r0->set == 'P') {
        IMCC_INFO(interp)->keyvec |= KEY_BIT(1);
        MK_I(interp, unit, "set %s[%s], %s", 3, r0, r1, r2);
    }
    else
        IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
            "unsupported indexed set op\n");

    return NULL;
}

PARROT_WARN_UNUSED_RESULT
PARROT_CAN_RETURN_NULL
static const char *
inv_op(ARGIN(const char *op))
{
    ASSERT_ARGS(inv_op)
    int n;
    return get_neg_op(op, &n);
}

PARROT_CANNOT_RETURN_NULL
Instruction *
IMCC_create_itcall_label(PARROT_INTERP)
{
    ASSERT_ARGS(IMCC_create_itcall_label)
    char         name[128];
    SymReg      *r;
    Instruction *i;

    snprintf(name, sizeof (name), "%cpcc_sub_call_%d", IMCC_INTERNAL_CHAR,
        IMCC_INFO(interp)->cnr++);

    r       = mk_pcc_sub(interp, name, 0);
    i       = iLABEL(interp, IMCC_INFO(interp)->cur_unit, r);
    i->type = ITCALL | ITPCCSUB;

    IMCC_INFO(interp)->cur_call = r;

    return i;
}

PARROT_CANNOT_RETURN_NULL
static SymReg *
mk_sub_address_fromc(PARROT_INTERP, ARGIN(const char *name))
{
    ASSERT_ARGS(mk_sub_address_fromc)
    /* name is a quoted sub name */
    SymReg *r;
    char *name_copy                  = str_dup(name + 1);
    name_copy[strlen(name_copy) - 1] = '\0';

    r = mk_sub_address(interp, name_copy);
    mem_sys_free(name_copy);

    return r;
}

PARROT_CANNOT_RETURN_NULL
static SymReg *
mk_sub_address_u(PARROT_INTERP, ARGIN(const char *name))
{
    ASSERT_ARGS(mk_sub_address_u)
    SymReg * const r = mk_sub_address(interp, name);
    r->type         |= VT_ENCODED;

    return r;
}

void
IMCC_itcall_sub(PARROT_INTERP, ARGIN(SymReg *sub))
{
    ASSERT_ARGS(IMCC_itcall_sub)
    IMCC_INFO(interp)->cur_call->pcc_sub->sub = sub;
    if (IMCC_INFO(interp)->cur_obj) {
        if (IMCC_INFO(interp)->cur_obj->set != 'P')
            IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR, "object isn't a PMC");
        IMCC_INFO(interp)->cur_call->pcc_sub->object = IMCC_INFO(interp)->cur_obj;
        IMCC_INFO(interp)->cur_obj = NULL;
    }
    if (IMCC_INFO(interp)->cur_call->pcc_sub->sub->pmc_type == enum_class_NCI)
        IMCC_INFO(interp)->cur_call->pcc_sub->flags |= isNCI;
    if (IMCC_INFO(interp)->cur_unit->type == IMC_PCCSUB)
        IMCC_INFO(interp)->cur_unit->instructions->symregs[0]->pcc_sub->calls_a_sub |= 1;
}

static void
begin_return_or_yield(PARROT_INTERP, int yield)
{
    ASSERT_ARGS(begin_return_or_yield)
    Instruction *i;
    Instruction * const ins = IMCC_INFO(interp)->cur_unit->instructions;
    char                name[128];

    if (!ins || !ins->symregs[0] || !(ins->symregs[0]->type & VT_PCC_SUB))
        IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                    "yield or return directive outside pcc subroutine\n");
    if (yield)
       ins->symregs[0]->pcc_sub->calls_a_sub = 1 | ITPCCYIELD;
    snprintf(name, sizeof (name), yield ? "%cpcc_sub_yield_%d" : "%cpcc_sub_ret_%d",
            IMCC_INTERNAL_CHAR, IMCC_INFO(interp)->cnr++);
    interp->imc_info->sr_return = mk_pcc_sub(interp, name, 0);
    i = iLABEL(interp, IMCC_INFO(interp)->cur_unit, interp->imc_info->sr_return);
    i->type = yield ? ITPCCSUB | ITLABEL | ITPCCYIELD : ITPCCSUB | ITLABEL ;
    interp->imc_info->asm_state = yield ? AsmInYield : AsmInReturn;
}

static void
set_lexical(PARROT_INTERP, ARGMOD(SymReg *r), ARGIN(const char *name))
{
    ASSERT_ARGS(set_lexical)
    SymReg * const n = mk_const(interp, name, 'S');

    r->usage |= U_LEXICAL;

    if (n == r->reg)
        IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
            "register %s already declared as lexical %s", r->name, n->name);

    /* chain all names in r->reg */
    n->reg = r->reg;
    r->reg = n;
    r->use_count++;
}

static void
add_pcc_named_arg(PARROT_INTERP, ARGMOD(SymReg *cur_call), ARGIN(const char *name),
        ARGIN(SymReg *value))
{
    ASSERT_ARGS(add_pcc_named_arg)
    SymReg * const r = mk_const(interp, name, 'S');

    r->type  |= VT_NAMED;

    add_pcc_arg(cur_call, r);
    add_pcc_arg(cur_call, value);
}

static void
add_pcc_named_result(PARROT_INTERP, ARGMOD(SymReg *cur_call), ARGIN(const char *name),
        ARGIN(SymReg *value))
{
    ASSERT_ARGS(add_pcc_named_result)
    SymReg * const r = mk_const(interp, name, 'S');
    r->type         |= VT_NAMED;

    add_pcc_result(cur_call, r);
    add_pcc_result(cur_call, value);
}

static void
add_pcc_named_param(PARROT_INTERP, ARGMOD(SymReg *cur_call), ARGIN(const char *name),
        ARGIN(SymReg *value))
{
    ASSERT_ARGS(add_pcc_named_param)
    SymReg * const r = mk_const(interp, name, 'S');
    r->type         |= VT_NAMED;

    add_pcc_arg(cur_call, r);
    add_pcc_arg(cur_call, value);
}

static void
add_pcc_named_return(PARROT_INTERP, ARGMOD(SymReg *cur_call), ARGIN(const char *name),
        ARGIN(SymReg *value))
{
    ASSERT_ARGS(add_pcc_named_return)
    SymReg * const r = mk_const(interp, name, 'S');
    r->type         |= VT_NAMED;

    add_pcc_result(cur_call, r);
    add_pcc_result(cur_call, value);
}

/* XXX Can name be consted? */
static void
adv_named_set(PARROT_INTERP, ARGIN(char *name))
{
    ASSERT_ARGS(adv_named_set)
    if (IMCC_INFO(interp)->adv_named_id) {
        IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                    "Named parameter with more than one name.\n");
    }
    IMCC_INFO(interp)->adv_named_id = name;
}

static void
do_loadlib(PARROT_INTERP, ARGIN(const char *lib))
{
    ASSERT_ARGS(do_loadlib)
    STRING * const s = string_unescape_cstring(interp, lib + 1, '"', NULL);
    PMC    *ignored  = Parrot_load_lib(interp, s, NULL);
    UNUSED(ignored);
    Parrot_register_HLL_lib(interp, s);
}

/* HEADERIZER STOP */



/* Enabling traces.  */
#ifndef YYDEBUG
# define YYDEBUG 0
#endif

/* Enabling verbose error messages.  */
#ifdef YYERROR_VERBOSE
# undef YYERROR_VERBOSE
# define YYERROR_VERBOSE 1
#else
# define YYERROR_VERBOSE 0
#endif

/* Enabling the token table.  */
#ifndef YYTOKEN_TABLE
# define YYTOKEN_TABLE 0
#endif

#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE
#line 785 "compilers/imcc/imcc.y"
{
    IdList * idlist;
    int t;
    char * s;
    SymReg * sr;
    Instruction *i;
}
/* Line 187 of yacc.c.  */
#line 1130 "compilers/imcc/imcparser.c"
	YYSTYPE;
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
# define YYSTYPE_IS_TRIVIAL 1
#endif



/* Copy the second part of user declarations.  */


/* Line 216 of yacc.c.  */
#line 1143 "compilers/imcc/imcparser.c"

#ifdef short
# undef short
#endif

#ifdef YYTYPE_UINT8
typedef YYTYPE_UINT8 yytype_uint8;
#else
typedef unsigned char yytype_uint8;
#endif

#ifdef YYTYPE_INT8
typedef YYTYPE_INT8 yytype_int8;
#elif (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
typedef signed char yytype_int8;
#else
typedef short int yytype_int8;
#endif

#ifdef YYTYPE_UINT16
typedef YYTYPE_UINT16 yytype_uint16;
#else
typedef unsigned short int yytype_uint16;
#endif

#ifdef YYTYPE_INT16
typedef YYTYPE_INT16 yytype_int16;
#else
typedef short int yytype_int16;
#endif

#ifndef YYSIZE_T
# ifdef __SIZE_TYPE__
#  define YYSIZE_T __SIZE_TYPE__
# elif defined size_t
#  define YYSIZE_T size_t
# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
#  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
#  define YYSIZE_T size_t
# else
#  define YYSIZE_T unsigned int
# endif
#endif

#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)

#ifndef YY_
# if YYENABLE_NLS
#  if ENABLE_NLS
#   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
#   define YY_(msgid) dgettext ("bison-runtime", msgid)
#  endif
# endif
# ifndef YY_
#  define YY_(msgid) msgid
# endif
#endif

/* Suppress unused-variable warnings by "using" E.  */
#if ! defined lint || defined __GNUC__
# define YYUSE(e) ((void) (e))
#else
# define YYUSE(e) /* empty */
#endif

/* Identity function, used to suppress warnings about constant conditions.  */
#ifndef lint
# define YYID(n) (n)
#else
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static int
YYID (int i)
#else
static int
YYID (i)
    int i;
#endif
{
  return i;
}
#endif

#if ! defined yyoverflow || YYERROR_VERBOSE

/* The parser invokes alloca or malloc; define the necessary symbols.  */

# ifdef YYSTACK_USE_ALLOCA
#  if YYSTACK_USE_ALLOCA
#   ifdef __GNUC__
#    define YYSTACK_ALLOC __builtin_alloca
#   elif defined __BUILTIN_VA_ARG_INCR
#    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
#   elif defined _AIX
#    define YYSTACK_ALLOC __alloca
#   elif defined _MSC_VER
#    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
#    define alloca _alloca
#   else
#    define YYSTACK_ALLOC alloca
#    if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
#     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
#     ifndef _STDLIB_H
#      define _STDLIB_H 1
#     endif
#    endif
#   endif
#  endif
# endif

# ifdef YYSTACK_ALLOC
   /* Pacify GCC's `empty if-body' warning.  */
#  define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
#  ifndef YYSTACK_ALLOC_MAXIMUM
    /* The OS might guarantee only one guard page at the bottom of the stack,
       and a page size can be as small as 4096 bytes.  So we cannot safely
       invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
       to allow for a few compiler-allocated temporary stack slots.  */
#   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
#  endif
# else
#  define YYSTACK_ALLOC YYMALLOC
#  define YYSTACK_FREE YYFREE
#  ifndef YYSTACK_ALLOC_MAXIMUM
#   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
#  endif
#  if (defined __cplusplus && ! defined _STDLIB_H \
       && ! ((defined YYMALLOC || defined malloc) \
	     && (defined YYFREE || defined free)))
#   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
#   ifndef _STDLIB_H
#    define _STDLIB_H 1
#   endif
#  endif
#  ifndef YYMALLOC
#   define YYMALLOC malloc
#   if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
#   endif
#  endif
#  ifndef YYFREE
#   define YYFREE free
#   if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
void free (void *); /* INFRINGES ON USER NAME SPACE */
#   endif
#  endif
# endif
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */


#if (! defined yyoverflow \
     && (! defined __cplusplus \
	 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))

/* A type that is properly aligned for any stack member.  */
union yyalloc
{
  yytype_int16 yyss;
  YYSTYPE yyvs;
  };

/* The size of the maximum gap between one aligned stack and the next.  */
# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)

/* The size of an array large to enough to hold all stacks, each with
   N elements.  */
# define YYSTACK_BYTES(N) \
     ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
      + YYSTACK_GAP_MAXIMUM)

/* Copy COUNT objects from FROM to TO.  The source and destination do
   not overlap.  */
# ifndef YYCOPY
#  if defined __GNUC__ && 1 < __GNUC__
#   define YYCOPY(To, From, Count) \
      __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
#  else
#   define YYCOPY(To, From, Count)		\
      do					\
	{					\
	  YYSIZE_T yyi;				\
	  for (yyi = 0; yyi < (Count); yyi++)	\
	    (To)[yyi] = (From)[yyi];		\
	}					\
      while (YYID (0))
#  endif
# endif

/* Relocate STACK from its old location to the new one.  The
   local variables YYSIZE and YYSTACKSIZE give the old and new number of
   elements in the stack, and YYPTR gives the new location of the
   stack.  Advance YYPTR to a properly aligned location for the next
   stack.  */
# define YYSTACK_RELOCATE(Stack)					\
    do									\
      {									\
	YYSIZE_T yynewbytes;						\
	YYCOPY (&yyptr->Stack, Stack, yysize);				\
	Stack = &yyptr->Stack;						\
	yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
	yyptr += yynewbytes / sizeof (*yyptr);				\
      }									\
    while (YYID (0))

#endif

/* YYFINAL -- State number of the termination state.  */
#define YYFINAL  33
/* YYLAST -- Last index in YYTABLE.  */
#define YYLAST   666

/* YYNTOKENS -- Number of terminals.  */
#define YYNTOKENS  139
/* YYNNTS -- Number of nonterminals.  */
#define YYNNTS  126
/* YYNRULES -- Number of rules.  */
#define YYNRULES  333
/* YYNRULES -- Number of states.  */
#define YYNSTATES  536

/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
#define YYUNDEFTOK  2
#define YYMAXUTOK   376

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

/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
static const yytype_uint8 yytranslate[] =
{
       0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       4,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,   129,     2,     2,     2,   135,   136,     2,
     126,   127,   133,   132,     2,   131,     2,   134,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,   138,
       2,   123,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,   124,     2,   125,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
     128,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,   137,     2,   130,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
       2,     2,     2,     2,     2,     2,     1,     2,     3,     5,
       6,     7,     8,     9,    10,    11,    12,    13,    14,    15,
      16,    17,    18,    19,    20,    21,    22,    23,    24,    25,
      26,    27,    28,    29,    30,    31,    32,    33,    34,    35,
      36,    37,    38,    39,    40,    41,    42,    43,    44,    45,
      46,    47,    48,    49,    50,    51,    52,    53,    54,    55,
      56,    57,    58,    59,    60,    61,    62,    63,    64,    65,
      66,    67,    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,   102,   103,   104,   105,
     106,   107,   108,   109,   110,   111,   112,   113,   114,   115,
     116,   117,   118,   119,   120,   121,   122
};

#if YYDEBUG
/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
   YYRHS.  */
static const yytype_uint16 yyprhs[] =
{
       0,     0,     3,     5,     7,    10,    12,    14,    16,    18,
      21,    23,    25,    27,    30,    34,    40,    44,    49,    52,
      57,    58,    65,    66,    73,    74,    81,    83,    85,    87,
      90,    94,    97,    99,   101,   103,   105,   107,   108,   112,
     113,   118,   121,   126,   127,   129,   130,   135,   136,   138,
     142,   146,   149,   150,   151,   152,   163,   164,   166,   170,
     171,   175,   179,   184,   189,   194,   196,   201,   203,   208,
     210,   215,   220,   222,   227,   228,   232,   234,   236,   238,
     240,   242,   244,   246,   250,   251,   253,   254,   264,   265,
     268,   269,   273,   274,   276,   278,   281,   283,   285,   287,
     289,   291,   293,   295,   297,   299,   301,   303,   305,   307,
     309,   315,   319,   323,   327,   331,   337,   343,   344,   348,
     351,   352,   356,   360,   361,   366,   367,   370,   372,   374,
     376,   378,   383,   385,   386,   392,   394,   395,   401,   402,
     405,   409,   410,   413,   417,   421,   425,   426,   432,   434,
     436,   437,   439,   443,   447,   453,   455,   458,   459,   462,
     465,   467,   469,   471,   473,   474,   476,   479,   481,   483,
     487,   490,   492,   496,   499,   500,   502,   504,   506,   507,
     512,   517,   518,   525,   527,   528,   535,   538,   541,   544,
     547,   549,   551,   553,   555,   556,   558,   560,   562,   564,
     566,   570,   575,   581,   588,   595,   603,   607,   608,   618,
     620,   622,   624,   628,   630,   632,   634,   636,   638,   640,
     642,   644,   646,   648,   650,   652,   654,   656,   658,   660,
     662,   664,   666,   668,   670,   672,   674,   676,   678,   680,
     681,   687,   691,   693,   695,   697,   699,   701,   703,   705,
     707,   709,   711,   713,   715,   717,   722,   724,   726,   728,
     730,   734,   738,   742,   743,   749,   750,   754,   756,   762,
     766,   769,   770,   773,   775,   777,   782,   785,   789,   795,
     797,   801,   802,   804,   806,   813,   819,   824,   829,   836,
     842,   844,   846,   848,   850,   852,   854,   856,   858,   860,
     862,   863,   865,   869,   871,   873,   878,   882,   884,   886,
     888,   890,   892,   894,   896,   898,   900,   902,   904,   905,
     908,   909,   912,   914,   918,   920,   922,   924,   926,   928,
     930,   932,   934,   936
};

/* YYRHS -- A `-1'-separated list of the rules' RHS.  */
static const yytype_int16 yyrhs[] =
{
     140,     0,    -1,   141,    -1,   142,    -1,   141,   142,    -1,
     162,    -1,   147,    -1,   164,    -1,   159,    -1,   111,     4,
      -1,   143,    -1,   144,    -1,     4,    -1,   146,     4,    -1,
      97,   113,     4,    -1,     8,   114,    72,   113,     4,    -1,
       9,   113,     4,    -1,    32,   113,    72,   264,    -1,     6,
     113,    -1,     7,   113,   123,   113,    -1,    -1,    31,   148,
     223,   109,   123,   264,    -1,    -1,    31,   150,   114,   255,
     123,   152,    -1,    -1,    31,   151,   113,   255,   123,   152,
      -1,   113,    -1,   116,    -1,   154,    -1,   153,   154,    -1,
     212,   155,     4,    -1,   111,     4,    -1,   120,    -1,   119,
      -1,   162,    -1,   149,    -1,   143,    -1,    -1,   156,   117,
     158,    -1,    -1,    78,   157,   186,   102,    -1,    14,   256,
      -1,    30,   113,    72,   110,    -1,    -1,   249,    -1,    -1,
     103,   160,   161,   104,    -1,    -1,   153,    -1,    25,   163,
       4,    -1,   124,   257,   125,    -1,   124,   125,    -1,    -1,
      -1,    -1,    27,   165,   252,   166,   186,     4,   167,   168,
     181,    73,    -1,    -1,     4,    -1,   168,   169,     4,    -1,
      -1,     5,   170,   171,    -1,   223,   109,   195,    -1,    95,
     126,   179,   127,    -1,    93,   126,   113,   127,    -1,    93,
     126,   109,   127,    -1,    96,    -1,    96,   126,   113,   127,
      -1,    91,    -1,    91,   126,   152,   127,    -1,   100,    -1,
     100,   126,   152,   127,    -1,    98,   126,   113,   127,    -1,
      99,    -1,    99,   126,   152,   127,    -1,    -1,   179,    72,
     180,    -1,   180,    -1,    52,    -1,    53,    -1,    55,    -1,
      54,    -1,   109,    -1,   113,    -1,   124,   257,   125,    -1,
      -1,   209,    -1,    -1,    75,     4,   183,   190,   185,   189,
     184,   192,    76,    -1,    -1,   214,     4,    -1,    -1,    85,
     256,     4,    -1,    -1,   187,    -1,   188,    -1,   187,   188,
      -1,    87,    -1,    88,    -1,    86,    -1,    89,    -1,    90,
      -1,    92,    -1,    94,    -1,   172,    -1,   173,    -1,   174,
      -1,   175,    -1,   176,    -1,   177,    -1,   178,    -1,    77,
     256,    72,   256,     4,    -1,    77,   256,     4,    -1,    83,
     256,     4,    -1,    84,   248,     4,    -1,    84,   113,     4,
      -1,    84,   248,    72,   256,     4,    -1,    84,   113,    72,
     256,     4,    -1,    -1,   190,   191,     4,    -1,    11,   238,
      -1,    -1,   192,   193,     4,    -1,    63,   248,   195,    -1,
      -1,    29,   194,   223,   217,    -1,    -1,   195,   196,    -1,
      18,    -1,    19,    -1,    20,    -1,    21,    -1,    21,   126,
     113,   127,    -1,   101,    -1,    -1,    79,     4,   198,   201,
      80,    -1,   205,    -1,    -1,    81,     4,   200,   202,    82,
      -1,    -1,   201,     4,    -1,   201,   203,     4,    -1,    -1,
     202,     4,    -1,   202,   204,     4,    -1,    15,   256,   239,
      -1,    16,   256,   239,    -1,    -1,   207,   126,   206,   208,
     127,    -1,    64,    -1,    66,    -1,    -1,   238,    -1,   113,
      22,   256,    -1,   208,    72,   238,    -1,   208,    72,   113,
      22,   256,    -1,   211,    -1,   209,   211,    -1,    -1,   210,
     215,    -1,   111,     4,    -1,   120,    -1,   119,    -1,   144,
      -1,   145,    -1,    -1,   213,    -1,   213,   214,    -1,   214,
      -1,   102,    -1,   212,   219,     4,    -1,     1,     4,    -1,
     217,    -1,   216,    72,   217,    -1,   109,   218,    -1,    -1,
     101,    -1,   225,    -1,   243,    -1,    -1,    29,   220,   223,
     216,    -1,    30,   113,    72,   248,    -1,    -1,    31,   221,
     223,   109,   123,   264,    -1,   149,    -1,    -1,    35,   222,
     223,   109,   123,   264,    -1,    65,   235,    -1,    10,   254,
      -1,   117,   249,    -1,    14,   256,    -1,   235,    -1,   182,
      -1,   197,    -1,   199,    -1,    -1,    52,    -1,    53,    -1,
      54,    -1,    55,    -1,   109,    -1,   248,   123,   256,    -1,
     248,   123,   227,   256,    -1,   248,   123,   256,   228,   256,
      -1,   248,   123,   256,   124,   257,   125,    -1,   248,   124,
     257,   125,   123,   256,    -1,   248,   123,   128,   224,   124,
     257,   125,    -1,   248,   123,   235,    -1,    -1,   126,   226,
     242,   127,   123,   234,   126,   237,   127,    -1,   229,    -1,
     231,    -1,   233,    -1,   248,   123,    14,    -1,   129,    -1,
     130,    -1,   131,    -1,   131,    -1,   132,    -1,   133,    -1,
     134,    -1,   135,    -1,    44,    -1,    68,    -1,   122,    -1,
      57,    -1,    58,    -1,    59,    -1,    60,    -1,    61,    -1,
      62,    -1,    50,    -1,    51,    -1,    69,    -1,    70,    -1,
      71,    -1,    56,    -1,   136,    -1,   137,    -1,   130,    -1,
      -1,    67,   230,   126,   242,   127,    -1,   248,   232,   256,
      -1,    36,    -1,    37,    -1,    38,    -1,    39,    -1,    46,
      -1,    45,    -1,    40,    -1,    41,    -1,    42,    -1,    43,
      -1,    47,    -1,    48,    -1,    49,    -1,   248,   123,   117,
     158,    -1,   109,    -1,   113,    -1,   116,    -1,   248,    -1,
     248,   121,   253,    -1,   248,   121,   113,    -1,   248,   121,
     248,    -1,    -1,   234,   236,   126,   237,   127,    -1,    -1,
     237,    72,   238,    -1,   238,    -1,   237,    72,   113,    22,
     256,    -1,   113,    22,   256,    -1,   256,   239,    -1,    -1,
     239,   240,    -1,    17,    -1,    21,    -1,    21,   126,   113,
     127,    -1,   248,   195,    -1,   242,    72,   241,    -1,   242,
      72,   113,    22,   248,    -1,   241,    -1,   113,    22,   248,
      -1,    -1,   245,    -1,   244,    -1,    13,   256,   247,   256,
      10,   254,    -1,    13,    14,   256,    10,   254,    -1,    13,
     256,   246,   254,    -1,    12,   256,   246,   254,    -1,    12,
     256,   247,   256,    10,   254,    -1,    12,    14,   256,    10,
     254,    -1,    72,    -1,    10,    -1,    57,    -1,    58,    -1,
      59,    -1,    60,    -1,    61,    -1,    62,    -1,   118,    -1,
     263,    -1,    -1,   250,    -1,   250,    72,   251,    -1,   251,
      -1,   255,    -1,   248,   124,   257,   125,    -1,   124,   259,
     125,    -1,   253,    -1,   113,    -1,   116,    -1,   109,    -1,
     117,    -1,   109,    -1,   117,    -1,   254,    -1,   256,    -1,
     248,    -1,   264,    -1,    -1,   258,   261,    -1,    -1,   260,
     261,    -1,   262,    -1,   261,   138,   262,    -1,   256,    -1,
     105,    -1,   106,    -1,   107,    -1,   108,    -1,   110,    -1,
     114,    -1,   115,    -1,   113,    -1,   116,    -1
};

/* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
static const yytype_uint16 yyrline[] =
{
       0,   880,   880,   884,   885,   889,   890,   891,   897,   903,
     904,   905,   906,   910,   911,   920,   925,   932,   944,   953,
     971,   971,   980,   980,   986,   986,   993,   994,   998,   999,
    1003,  1004,  1005,  1006,  1007,  1008,  1009,  1012,  1012,  1021,
    1020,  1032,  1036,  1044,  1048,  1052,  1052,  1064,  1066,  1070,
    1085,  1093,  1098,  1102,  1106,  1097,  1118,  1119,  1120,  1133,
    1133,  1137,  1151,  1155,  1161,  1170,  1176,  1185,  1191,  1200,
    1206,  1215,  1223,  1228,  1239,  1242,  1247,  1255,  1256,  1257,
    1258,  1259,  1270,  1281,  1284,  1286,  1291,  1290,  1323,  1324,
    1328,  1329,  1333,  1334,  1338,  1339,  1343,  1344,  1345,  1346,
    1347,  1348,  1349,  1350,  1351,  1352,  1353,  1354,  1355,  1356,
    1360,  1365,  1369,  1374,  1378,  1382,  1387,  1396,  1397,  1401,
    1406,  1407,  1415,  1416,  1416,  1431,  1432,  1436,  1437,  1438,
    1439,  1440,  1441,  1446,  1446,  1449,  1457,  1457,  1463,  1464,
    1469,  1477,  1478,  1483,  1491,  1495,  1500,  1499,  1512,  1513,
    1517,  1518,  1528,  1532,  1542,  1550,  1551,  1563,  1567,  1569,
    1570,  1571,  1572,  1573,  1577,  1578,  1582,  1583,  1587,  1596,
    1597,  1608,  1615,  1624,  1634,  1635,  1640,  1641,  1642,  1642,
    1658,  1662,  1662,  1669,  1670,  1670,  1676,  1682,  1683,  1695,
    1696,  1697,  1698,  1699,  1700,  1704,  1705,  1706,  1707,  1711,
    1724,  1726,  1728,  1730,  1732,  1737,  1740,  1747,  1746,  1755,
    1756,  1757,  1758,  1766,  1767,  1768,  1772,  1773,  1774,  1775,
    1776,  1777,  1778,  1779,  1780,  1781,  1782,  1783,  1784,  1785,
    1786,  1787,  1788,  1789,  1790,  1791,  1792,  1793,  1794,  1800,
    1799,  1811,  1818,  1819,  1820,  1821,  1822,  1823,  1824,  1825,
    1826,  1827,  1828,  1829,  1830,  1835,  1846,  1847,  1848,  1849,
    1855,  1869,  1875,  1881,  1880,  1889,  1890,  1900,  1910,  1916,
    1925,  1929,  1930,  1934,  1935,  1938,  1942,  1946,  1956,  1961,
    1971,  1976,  1980,  1981,  1985,  1989,  1993,  2000,  2004,  2008,
    2015,  2016,  2020,  2021,  2022,  2023,  2024,  2025,  2029,  2030,
    2034,  2035,  2039,  2040,  2044,  2045,  2052,  2059,  2060,  2061,
    2065,  2066,  2070,  2071,  2075,  2076,  2080,  2081,  2085,  2085,
    2098,  2098,  2111,  2112,  2120,  2129,  2130,  2131,  2132,  2133,
    2137,  2138,  2139,  2140
};
#endif

#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
   First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
static const char *const yytname[] =
{
  "$end", "error", "$undefined", "LOW_PREC", "'\\n'", "PARAM", "HLL",
  "HLL_MAP", "TK_LINE", "TK_FILE", "GOTO", "ARG", "IF", "UNLESS", "PNULL",
  "SET_RETURN", "SET_YIELD", "ADV_FLAT", "ADV_SLURPY", "ADV_OPTIONAL",
  "ADV_OPT_FLAG", "ADV_NAMED", "ADV_ARROW", "NEW", "ADV_INVOCANT",
  "NAMESPACE", "DOT_METHOD", "SUB", "SYM", "LOCAL", "LEXICAL", "CONST",
  "ANNOTATE", "INC", "DEC", "GLOBAL_CONST", "PLUS_ASSIGN", "MINUS_ASSIGN",
  "MUL_ASSIGN", "DIV_ASSIGN", "CONCAT_ASSIGN", "BAND_ASSIGN", "BOR_ASSIGN",
  "BXOR_ASSIGN", "FDIV", "FDIV_ASSIGN", "MOD_ASSIGN", "SHR_ASSIGN",
  "SHL_ASSIGN", "SHR_U_ASSIGN", "SHIFT_LEFT", "SHIFT_RIGHT", "INTV",
  "FLOATV", "STRINGV", "PMCV", "LOG_XOR", "RELOP_EQ", "RELOP_NE",
  "RELOP_GT", "RELOP_GTE", "RELOP_LT", "RELOP_LTE", "RESULT", "RETURN",
  "TAILCALL", "YIELDT", "GET_RESULTS", "POW", "SHIFT_RIGHT_U", "LOG_AND",
  "LOG_OR", "COMMA", "ESUB", "DOTDOT", "PCC_BEGIN", "PCC_END", "PCC_CALL",
  "PCC_SUB", "PCC_BEGIN_RETURN", "PCC_END_RETURN", "PCC_BEGIN_YIELD",
  "PCC_END_YIELD", "NCI_CALL", "METH_CALL", "INVOCANT", "MAIN", "LOAD",
  "INIT", "IMMEDIATE", "POSTCOMP", "METHOD", "ANON", "OUTER", "NEED_LEX",
  "MULTI", "VTABLE_METHOD", "LOADLIB", "SUB_INSTANCE_OF", "SUBID",
  "NS_ENTRY", "UNIQUE_REG", "LABEL", "EMIT", "EOM", "IREG", "NREG", "SREG",
  "PREG", "IDENTIFIER", "REG", "MACRO", "ENDM", "STRINGC", "INTC",
  "FLOATC", "USTRINGC", "PARROT_OP", "VAR", "LINECOMMENT", "FILECOMMENT",
  "DOT", "CONCAT", "'='", "'['", "']'", "'('", "')'", "'new'", "'!'",
  "'~'", "'-'", "'+'", "'*'", "'/'", "'%'", "'&'", "'|'", "';'", "$accept",
  "program", "compilation_units", "compilation_unit", "pragma",
  "location_directive", "annotate_directive", "hll_def", "constdef", "@1",
  "pmc_const", "@2", "@3", "any_string", "pasmcode", "pasmline",
  "pasm_inst", "@4", "@5", "pasm_args", "emit", "@6", "opt_pasmcode",
  "class_namespace", "maybe_ns", "sub", "@7", "@8", "@9", "sub_params",
  "sub_param", "@10", "sub_param_type_def", "multi", "outer", "vtable",
  "method", "ns_entry_name", "instanceof", "subid", "multi_types",
  "multi_type", "sub_body", "pcc_sub_call", "@11", "opt_label",
  "opt_invocant", "sub_proto", "sub_proto_list", "proto", "pcc_call",
  "pcc_args", "pcc_arg", "pcc_results", "pcc_result", "@12",
  "paramtype_list", "paramtype", "pcc_ret", "@13", "pcc_yield", "@14",
  "pcc_returns", "pcc_yields", "pcc_return", "pcc_set_yield",
  "pcc_return_many", "@15", "return_or_yield", "var_returns", "statements",
  "helper_clear_state", "statement", "labels", "_labels", "label",
  "instruction", "id_list", "id_list_id", "opt_unique_reg", "labeled_inst",
  "@16", "@17", "@18", "type", "classname", "assignment", "@19", "un_op",
  "bin_op", "get_results", "@20", "op_assign", "assign_op", "func_assign",
  "the_sub", "sub_call", "@21", "arglist", "arg", "argtype_list",
  "argtype", "result", "targetlist", "conditional_statement",
  "unless_statement", "if_statement", "comma_or_goto", "relop", "target",
  "vars", "_vars", "_var_or_i", "sub_label_op_c", "sub_label_op",
  "label_op", "var_or_i", "var", "keylist", "@22", "keylist_force", "@23",
  "_keylist", "key", "reg", "const", 0
};
#endif

# ifdef YYPRINT
/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
   token YYLEX-NUM.  */
static const yytype_uint16 yytoknum[] =
{
       0,   256,   257,   258,    10,   259,   260,   261,   262,   263,
     264,   265,   266,   267,   268,   269,   270,   271,   272,   273,
     274,   275,   276,   277,   278,   279,   280,   281,   282,   283,
     284,   285,   286,   287,   288,   289,   290,   291,   292,   293,
     294,   295,   296,   297,   298,   299,   300,   301,   302,   303,
     304,   305,   306,   307,   308,   309,   310,   311,   312,   313,
     314,   315,   316,   317,   318,   319,   320,   321,   322,   323,
     324,   325,   326,   327,   328,   329,   330,   331,   332,   333,
     334,   335,   336,   337,   338,   339,   340,   341,   342,   343,
     344,   345,   346,   347,   348,   349,   350,   351,   352,   353,
     354,   355,   356,   357,   358,   359,   360,   361,   362,   363,
     364,   365,   366,   367,   368,   369,   370,   371,   372,   373,
     374,   375,   376,    61,    91,    93,    40,    41,   110,    33,
     126,    45,    43,    42,    47,    37,    38,   124,    59
};
# endif

/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
static const yytype_uint16 yyr1[] =
{
       0,   139,   140,   141,   141,   142,   142,   142,   142,   142,
     142,   142,   142,   143,   143,   144,   144,   145,   146,   146,
     148,   147,   150,   149,   151,   149,   152,   152,   153,   153,
     154,   154,   154,   154,   154,   154,   154,   156,   155,   157,
     155,   155,   155,   155,   158,   160,   159,   161,   161,   162,
     163,   163,   165,   166,   167,   164,   168,   168,   168,   170,
     169,   171,   172,   173,   173,   174,   174,   175,   175,   176,
     176,   177,   178,   178,   179,   179,   179,   180,   180,   180,
     180,   180,   180,   180,   181,   181,   183,   182,   184,   184,
     185,   185,   186,   186,   187,   187,   188,   188,   188,   188,
     188,   188,   188,   188,   188,   188,   188,   188,   188,   188,
     189,   189,   189,   189,   189,   189,   189,   190,   190,   191,
     192,   192,   193,   194,   193,   195,   195,   196,   196,   196,
     196,   196,   196,   198,   197,   197,   200,   199,   201,   201,
     201,   202,   202,   202,   203,   204,   206,   205,   207,   207,
     208,   208,   208,   208,   208,   209,   209,   210,   211,   211,
     211,   211,   211,   211,   212,   212,   213,   213,   214,   215,
     215,   216,   216,   217,   218,   218,   219,   219,   220,   219,
     219,   221,   219,   219,   222,   219,   219,   219,   219,   219,
     219,   219,   219,   219,   219,   223,   223,   223,   223,   224,
     225,   225,   225,   225,   225,   225,   225,   226,   225,   225,
     225,   225,   225,   227,   227,   227,   228,   228,   228,   228,
     228,   228,   228,   228,   228,   228,   228,   228,   228,   228,
     228,   228,   228,   228,   228,   228,   228,   228,   228,   230,
     229,   231,   232,   232,   232,   232,   232,   232,   232,   232,
     232,   232,   232,   232,   232,   233,   234,   234,   234,   234,
     234,   234,   234,   236,   235,   237,   237,   237,   237,   237,
     238,   239,   239,   240,   240,   240,   241,   242,   242,   242,
     242,   242,   243,   243,   244,   244,   244,   245,   245,   245,
     246,   246,   247,   247,   247,   247,   247,   247,   248,   248,
     249,   249,   250,   250,   251,   251,   251,   252,   252,   252,
     253,   253,   254,   254,   255,   255,   256,   256,   258,   257,
     260,   259,   261,   261,   262,   263,   263,   263,   263,   263,
     264,   264,   264,   264
};

/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
static const yytype_uint8 yyr2[] =
{
       0,     2,     1,     1,     2,     1,     1,     1,     1,     2,
       1,     1,     1,     2,     3,     5,     3,     4,     2,     4,
       0,     6,     0,     6,     0,     6,     1,     1,     1,     2,
       3,     2,     1,     1,     1,     1,     1,     0,     3,     0,
       4,     2,     4,     0,     1,     0,     4,     0,     1,     3,
       3,     2,     0,     0,     0,    10,     0,     1,     3,     0,
       3,     3,     4,     4,     4,     1,     4,     1,     4,     1,
       4,     4,     1,     4,     0,     3,     1,     1,     1,     1,
       1,     1,     1,     3,     0,     1,     0,     9,     0,     2,
       0,     3,     0,     1,     1,     2,     1,     1,     1,     1,
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
       5,     3,     3,     3,     3,     5,     5,     0,     3,     2,
       0,     3,     3,     0,     4,     0,     2,     1,     1,     1,
       1,     4,     1,     0,     5,     1,     0,     5,     0,     2,
       3,     0,     2,     3,     3,     3,     0,     5,     1,     1,
       0,     1,     3,     3,     5,     1,     2,     0,     2,     2,
       1,     1,     1,     1,     0,     1,     2,     1,     1,     3,
       2,     1,     3,     2,     0,     1,     1,     1,     0,     4,
       4,     0,     6,     1,     0,     6,     2,     2,     2,     2,
       1,     1,     1,     1,     0,     1,     1,     1,     1,     1,
       3,     4,     5,     6,     6,     7,     3,     0,     9,     1,
       1,     1,     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,     0,
       5,     3,     1,     1,     1,     1,     1,     1,     1,     1,
       1,     1,     1,     1,     1,     4,     1,     1,     1,     1,
       3,     3,     3,     0,     5,     0,     3,     1,     5,     3,
       2,     0,     2,     1,     1,     4,     2,     3,     5,     1,
       3,     0,     1,     1,     6,     5,     4,     4,     6,     5,
       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
       0,     1,     3,     1,     1,     4,     3,     1,     1,     1,
       1,     1,     1,     1,     1,     1,     1,     1,     0,     2,
       0,     2,     1,     3,     1,     1,     1,     1,     1,     1,
       1,     1,     1,     1
};

/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
   STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
   means the default is an error.  */
static const yytype_uint16 yydefact[] =
{
       0,    12,     0,     0,     0,     0,     0,    52,    20,     0,
      45,     0,     0,     2,     3,    10,    11,     0,     6,     8,
       5,     7,    18,     0,     0,     0,   318,     0,     0,     0,
       0,   164,     9,     1,     4,    13,     0,     0,    16,    51,
       0,     0,    49,   310,   308,   309,   311,    53,   307,   195,
     196,   197,   198,     0,    14,    22,   168,     0,    33,    32,
      36,    35,   164,    28,     0,    34,    37,   165,   167,    19,
       0,    50,   325,   326,   327,   328,   329,   332,   330,   331,
     333,   298,   316,   324,   319,   322,   299,   317,    92,     0,
       0,     0,    31,    29,    46,     0,     0,    39,     0,     0,
     166,    15,     0,    98,    96,    97,    99,   100,    67,   101,
       0,   102,     0,    65,     0,    72,    69,   103,   104,   105,
     106,   107,   108,   109,     0,    93,    94,     0,     0,     0,
      41,     0,    92,    30,   300,   323,     0,     0,    74,     0,
       0,     0,     0,    54,    95,    21,   312,   313,   314,     0,
     315,     0,     0,     0,   320,    38,   316,    44,   301,   303,
     304,    26,    27,     0,     0,     0,    77,    78,    80,    79,
      81,    82,   318,     0,    76,     0,     0,     0,     0,    56,
       0,     0,    42,    40,     0,     0,   318,     0,    68,    64,
      63,     0,     0,    62,    66,    71,    73,    70,    57,   157,
      23,    25,   306,   321,     0,   302,    83,    75,    59,     0,
       0,   161,   160,   162,   163,     0,     0,   157,     0,   155,
     305,     0,     0,   159,    58,    55,   156,     0,   194,   158,
      60,     0,     0,   170,     0,     0,     0,     0,   178,     0,
     181,   184,   148,     0,   149,   239,     0,     0,     0,   256,
     257,   258,   300,   207,   183,   191,   192,   193,   135,     0,
       0,   176,   209,   210,   211,   263,   190,   177,   283,   282,
     259,   125,    17,   187,     0,     0,     0,     0,   189,     0,
       0,     0,     0,   186,   259,     0,    86,   133,   136,   188,
     281,   146,   169,     0,   242,   243,   244,   245,   248,   249,
     250,   251,   247,   246,   252,   253,   254,     0,     0,   318,
       0,    61,     0,   291,   292,   293,   294,   295,   296,   297,
     290,     0,     0,     0,     0,     0,     0,     0,     0,     0,
     281,   117,   138,   141,     0,   279,     0,   125,   150,   265,
     261,   262,   260,   212,   332,   333,   300,     0,   213,   214,
     215,     0,   206,   316,   200,     0,   241,   127,   128,   129,
     130,   132,   126,     0,   287,     0,     0,   286,     0,   174,
     179,   171,   180,     0,     0,     0,    90,     0,     0,     0,
       0,     0,   276,   332,     0,   151,   271,   332,     0,   267,
     255,   199,     0,   201,   221,   230,   231,   235,   224,   225,
     226,   227,   228,   229,   222,   232,   233,   234,   223,   318,
     238,   216,   217,   218,   219,   220,   236,   237,     0,     0,
       0,   289,     0,   285,     0,   175,   173,     0,     0,     0,
     240,     0,     0,     0,     0,   139,     0,   134,     0,   142,
       0,   137,     0,   280,     0,   277,     0,     0,     0,   147,
     270,     0,     0,   264,   318,     0,   202,     0,     0,   288,
     284,   172,   182,   185,   119,     0,     0,     0,     0,    88,
     118,   271,   140,   271,   143,     0,     0,   152,   332,   153,
     273,   274,   272,   269,   332,   266,     0,   203,   204,   131,
      91,     0,     0,     0,     0,   120,     0,   144,   145,   278,
     265,     0,     0,     0,   205,   111,     0,   112,   114,     0,
     113,     0,     0,    89,     0,   154,     0,   268,     0,     0,
       0,   123,     0,    87,     0,   208,   275,   110,   116,   115,
       0,   125,   121,     0,   122,   124
};

/* YYDEFGOTO[NTERM-NUM].  */
static const yytype_int16 yydefgoto[] =
{
      -1,    12,    13,    14,    15,    16,   214,    17,    18,    29,
      61,    90,    91,   163,    62,    63,    98,    99,   132,   155,
      19,    31,    64,    20,    27,    21,    28,    88,   179,   199,
     215,   221,   230,   117,   118,   119,   120,   121,   122,   123,
     173,   174,   216,   255,   331,   495,   433,   124,   125,   126,
     469,   376,   434,   512,   524,   530,   311,   362,   256,   332,
     257,   333,   377,   378,   438,   442,   258,   338,   259,   384,
     217,   218,   219,    66,    67,    68,   229,   370,   371,   426,
     260,   279,   281,   282,    53,   392,   261,   290,   351,   418,
     262,   285,   263,   310,   264,   265,   266,   293,   388,   389,
     450,   482,   335,   336,   267,   268,   269,   321,   322,    82,
     157,   158,   159,    47,    48,   148,   160,   150,    40,    41,
     184,   185,    84,    85,    86,    87
};

/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
   STATE-NUM.  */
#define YYPACT_NINF -422
static const yytype_int16 yypact[] =
{
     358,  -422,   -75,   -19,   -67,     1,   -71,  -422,  -422,    20,
    -422,   145,   150,   358,  -422,  -422,  -422,   155,  -422,  -422,
    -422,  -422,  -422,    44,    96,   171,    51,   179,     2,   156,
     184,   110,  -422,  -422,  -422,  -422,    76,    79,  -422,  -422,
      68,   469,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,    89,  -422,    86,  -422,   199,  -422,  -422,
    -422,  -422,   216,  -422,   101,  -422,    54,   113,  -422,  -422,
     202,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,    87,  -422,  -422,  -422,   436,   103,
     114,   111,  -422,  -422,  -422,   469,   118,  -422,   223,   115,
    -422,  -422,   469,  -422,  -422,  -422,  -422,  -422,   108,  -422,
     112,  -422,   117,   120,   122,   131,   132,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,   233,   436,  -422,   104,   455,   455,
    -422,   167,   436,  -422,   389,  -422,    42,    12,   127,   140,
     146,    42,    42,  -422,  -422,  -422,  -422,  -422,  -422,   121,
    -422,   143,   135,   166,  -422,  -422,   152,  -422,   198,  -422,
    -422,  -422,  -422,   147,   151,   158,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,   -60,  -422,   159,   168,   173,   175,   275,
      42,    42,  -422,  -422,   157,   469,  -422,   389,  -422,  -422,
    -422,   169,   127,  -422,  -422,  -422,  -422,  -422,  -422,    34,
    -422,  -422,  -422,    87,   178,  -422,  -422,  -422,  -422,   170,
     308,  -422,  -422,  -422,  -422,   310,   246,    37,    21,  -422,
    -422,   156,   243,  -422,  -422,  -422,  -422,   318,   242,  -422,
    -422,   215,   104,  -422,   -69,   266,   314,   469,  -422,   212,
     -49,  -422,  -422,   183,  -422,  -422,   322,   335,   336,  -422,
    -422,  -422,   389,  -422,  -422,  -422,  -422,  -422,  -422,   217,
     340,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
     397,  -422,  -422,  -422,   469,   203,   469,   203,  -422,   156,
     274,   156,   156,  -422,   232,   228,  -422,  -422,  -422,  -422,
     432,  -422,  -422,   230,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,  -422,  -422,   224,    56,  -422,
     469,     8,   347,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,   -69,   469,   351,   -69,   469,   254,   346,   260,   261,
     432,  -422,  -422,  -422,   353,  -422,   -56,  -422,   483,   497,
    -422,  -422,  -422,  -422,   252,   262,   389,   277,  -422,  -422,
    -422,   469,  -422,   -85,   422,   268,  -422,  -422,  -422,  -422,
     270,  -422,  -422,   -69,  -422,   377,   -69,  -422,   384,   296,
     326,  -422,  -422,   278,   279,   -55,    -3,    17,     7,   346,
     539,   281,     8,   378,   -54,  -422,  -422,   383,   -52,  -422,
    -422,  -422,   284,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,   469,   286,
     299,  -422,   -69,  -422,   -69,  -422,  -422,   254,   104,   104,
    -422,   469,   469,    22,   409,  -422,   469,  -422,   410,  -422,
     469,  -422,   411,  -422,   395,  -422,   183,   469,   511,  -422,
     119,   469,   525,  -422,  -422,   293,  -422,   469,   304,  -422,
    -422,  -422,  -422,  -422,  -422,   419,   469,   469,   548,   113,
    -422,  -422,  -422,  -422,  -422,   346,   315,  -422,   425,  -422,
    -422,   323,  -422,  -422,   426,  -422,   325,  -422,  -422,  -422,
    -422,     5,   453,     9,    11,  -422,   454,   119,   119,  -422,
     497,   469,   350,   469,  -422,  -422,   469,  -422,  -422,   469,
    -422,   469,    15,  -422,   -48,  -422,   344,  -422,   463,   470,
     471,  -422,   346,  -422,   472,  -422,  -422,  -422,  -422,  -422,
     156,  -422,  -422,   254,     8,  -422
};

/* YYPGOTO[NTERM-NUM].  */
static const yytype_int16 yypgoto[] =
{
    -422,  -422,  -422,   464,    18,  -162,  -422,  -422,  -422,  -422,
     257,  -422,  -422,    10,  -422,   424,  -422,  -422,  -422,   141,
    -422,  -422,  -422,    28,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,   297,  -422,  -422,  -422,  -422,  -422,   356,  -422,   375,
    -422,  -422,  -422,  -422,  -422,  -422,  -330,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,   291,   283,  -422,   -66,  -422,  -422,  -421,  -422,
    -422,  -422,  -422,  -422,  -219,  -422,  -422,  -422,  -422,  -422,
    -422,  -422,  -422,  -422,  -422,    63,  -213,  -422,    14,  -328,
    -397,  -422,   130,   181,  -422,  -422,  -422,   235,   238,  -130,
     264,  -422,   330,  -422,   226,  -220,   -36,   -41,  -167,  -422,
    -422,  -422,   334,   439,  -422,  -124
};

/* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
   positive, shift that token.  If negative, reduce the rule which
   number is the opposite.  If zero, do what YYDEFACT says.
   If YYTABLE_NINF, syntax error.  */
#define YYTABLE_NINF -260
static const yytype_int16 yytable[] =
{
      83,   100,   231,   145,   156,   191,   461,   382,   431,   505,
     385,   439,   192,   508,   273,   510,   380,   380,   448,   204,
     452,   435,   227,   440,   452,  -164,   357,   358,   359,   360,
     283,  -164,   436,  -164,  -164,  -164,   307,   213,    22,   208,
     146,  -259,     4,     5,   521,     4,     5,    24,   147,    60,
    -164,  -164,  -164,    26,   130,   213,  -164,   156,   -43,    65,
     326,    83,   328,   329,   -24,   -22,   209,   193,    95,   209,
     343,   381,   430,   449,   497,   453,   498,   506,   522,   525,
      60,   509,   432,   511,    96,  -164,  -164,  -164,  -164,   441,
      65,   523,   149,   151,    23,   352,  -164,   437,   270,   466,
    -164,   364,  -164,   464,   367,   467,   468,   -84,   272,   361,
     -85,    43,   535,   284,    25,    44,     2,     3,    45,    46,
     479,   164,   156,    56,   485,   165,  -164,  -164,  -164,  -164,
    -164,  -164,    97,    30,  -164,     6,   480,  -164,  -164,  -164,
     481,    55,   355,   421,    83,   210,   423,  -164,   210,    32,
      33,   177,   178,   211,   212,   161,   211,   212,   162,    35,
     337,    72,    73,    74,    75,   249,    76,    36,    37,   344,
      78,    79,   345,   346,    81,    38,    39,   341,   353,   166,
     167,   168,   169,    42,   347,   348,   349,   350,    54,    69,
     200,   201,    70,    71,   275,   277,   278,   372,    89,   -24,
     337,   534,   459,    92,   460,    94,   101,     9,    49,    50,
      51,    52,    56,   313,   -47,    56,   156,    77,    78,    79,
      80,    57,     2,     3,   129,   102,   127,   133,   128,    58,
      59,   131,   134,   312,   136,   323,   170,   143,   137,   152,
     171,     6,   455,   138,   180,   182,   139,    55,   140,   443,
     337,   172,   234,   175,   235,   236,   237,   141,   142,   176,
     314,   315,   316,   317,   318,   319,   181,   354,   183,   356,
     187,   238,   239,   240,   188,   320,   186,   241,   189,   198,
     274,   365,   202,   222,   368,   190,   194,   486,    72,    73,
      74,    75,   249,    76,   206,   195,   250,   386,   386,   251,
     196,    81,   197,   220,   462,   463,   242,   243,   244,   245,
     393,   533,   223,     9,   224,   232,   284,   246,    56,   225,
     -48,   247,   233,   248,   271,   280,   286,    57,   276,    72,
      73,    74,    75,    43,    76,    58,    59,   340,   494,   287,
     288,    46,    81,   291,   292,   499,   327,    72,    73,    74,
      75,   249,    76,   307,   330,   250,   339,   363,   251,   252,
      81,   366,     1,   369,     2,     3,     4,     5,   253,   373,
     374,    72,    73,    74,    75,   379,    76,   456,  -257,    77,
      78,    79,    80,     6,    81,     7,   391,   422,  -258,     8,
     386,   465,   531,   419,   424,   471,   420,   425,   427,   473,
     447,   428,   429,   496,   446,   451,   477,   386,   454,   457,
     483,   386,   458,   470,   472,   474,   488,   475,   487,    72,
      73,    74,    75,   490,    76,   491,   492,    77,    78,    79,
      80,   489,    81,   294,   295,   296,   297,   298,   299,   300,
     301,   500,   302,   303,   304,   305,   306,   501,   503,   502,
     504,    72,    73,    74,    75,     9,    76,   507,   513,   386,
     515,    10,   517,   516,    81,   518,   394,   527,   519,    11,
     520,   526,   395,   396,   528,   529,   532,    34,   397,   398,
     399,   400,   401,   402,   403,   254,    93,   390,   153,   207,
     404,   405,   406,   407,    72,    73,    74,    75,   146,    76,
     144,   228,    77,    78,    79,    80,   147,    81,   226,   476,
     445,   375,   324,   154,   514,   325,   289,   205,   307,   203,
     308,   309,   103,   104,   105,   106,   107,   108,   109,   110,
     111,   112,   113,   342,   114,   115,   116,    72,    73,    74,
      75,   135,    76,     0,   408,   334,   409,     0,     0,     0,
      81,     0,   410,   411,   412,   413,   414,   415,   416,   417,
      72,    73,    74,    75,   146,    76,     0,     0,    77,    78,
      79,    80,   147,    81,    72,    73,    74,    75,     0,    76,
       0,     0,    77,    78,    79,    80,     0,    81,    72,    73,
      74,    75,     0,    76,     0,     0,   383,    78,    79,    80,
       0,    81,    72,    73,    74,    75,     0,    76,     0,     0,
     387,    78,    79,    80,     0,    81,    72,    73,    74,    75,
       0,    76,     0,     0,   478,    78,    79,    80,     0,    81,
      72,    73,    74,    75,     0,    76,     0,     0,   484,    78,
      79,    80,     0,    81,    72,    73,    74,    75,     0,    76,
       0,     0,   444,    72,    73,    74,    75,    81,    76,     0,
       0,   493,     0,     0,     0,     0,    81
};

static const yytype_int16 yycheck[] =
{
      41,    67,   221,   127,   134,   172,   427,   337,    11,     4,
     338,     4,    72,     4,   234,     4,    72,    72,    72,   186,
      72,     4,     1,    16,    72,     4,    18,    19,    20,    21,
     243,    10,    15,    12,    13,    14,   121,   199,   113,     5,
     109,   126,     8,     9,    29,     8,     9,   114,   117,    31,
      29,    30,    31,   124,    95,   217,    35,   187,     4,    31,
     279,   102,   281,   282,   113,   114,    32,   127,    14,    32,
      14,   127,   127,   127,   471,   127,   473,    72,    63,   127,
      62,    72,    85,    72,    30,    64,    65,    66,    67,    82,
      62,    76,   128,   129,   113,   308,    75,    80,   228,    77,
      79,   321,    81,   431,   324,    83,    84,    73,   232,   101,
      73,   109,   533,   243,   113,   113,     6,     7,   116,   117,
     448,   109,   252,   102,   452,   113,   105,   106,   107,   108,
     109,   110,    78,   113,   113,    25,    17,   116,   117,   118,
      21,    31,   309,   363,   185,   111,   366,   126,   111,     4,
       0,   141,   142,   119,   120,   113,   119,   120,   116,     4,
     290,   105,   106,   107,   108,   109,   110,   123,    72,   113,
     114,   115,   116,   117,   118,     4,   125,   307,   308,    52,
      53,    54,    55,     4,   128,   129,   130,   131,     4,   113,
     180,   181,   113,   125,   235,   236,   237,   327,   109,   113,
     330,   531,   422,     4,   424,   104,     4,    97,    52,    53,
      54,    55,   102,    10,   104,   102,   346,   113,   114,   115,
     116,   111,     6,     7,   113,   138,   123,     4,   114,   119,
     120,   113,   117,   274,   126,   276,   109,     4,   126,    72,
     113,    25,   409,   126,   123,   110,   126,    31,   126,   379,
     380,   124,    10,   113,    12,    13,    14,   126,   126,   113,
      57,    58,    59,    60,    61,    62,   123,   308,   102,   310,
      72,    29,    30,    31,   127,    72,   124,    35,   127,     4,
      14,   322,   125,   113,   325,   127,   127,   454,   105,   106,
     107,   108,   109,   110,   125,   127,   113,   338,   339,   116,
     127,   118,   127,   125,   428,   429,    64,    65,    66,    67,
     351,   530,     4,    97,     4,    72,   446,    75,   102,    73,
     104,    79,     4,    81,   109,   113,     4,   111,    14,   105,
     106,   107,   108,   109,   110,   119,   120,   113,   468,     4,
       4,   117,   118,   126,     4,   475,    72,   105,   106,   107,
     108,   109,   110,   121,   126,   113,   126,    10,   116,   117,
     118,    10,     4,   109,     6,     7,     8,     9,   126,   109,
     109,   105,   106,   107,   108,    22,   110,   418,   126,   113,
     114,   115,   116,    25,   118,    27,   109,    10,   126,    31,
     431,   432,   522,   125,    10,   436,   126,   101,    72,   440,
      22,   123,   123,   469,   123,    22,   447,   448,   124,   123,
     451,   452,   113,     4,     4,     4,   457,    22,   125,   105,
     106,   107,   108,     4,   110,   466,   467,   113,   114,   115,
     116,   127,   118,    36,    37,    38,    39,    40,    41,    42,
      43,   126,    45,    46,    47,    48,    49,    22,    22,   126,
     125,   105,   106,   107,   108,    97,   110,     4,     4,   500,
     501,   103,   503,   113,   118,   506,    44,     4,   509,   111,
     511,   127,    50,    51,     4,     4,     4,    13,    56,    57,
      58,    59,    60,    61,    62,   228,    62,   346,   132,   192,
      68,    69,    70,    71,   105,   106,   107,   108,   109,   110,
     125,   218,   113,   114,   115,   116,   117,   118,   217,   446,
     380,   330,   277,   124,   500,   277,   252,   187,   121,   185,
     123,   124,    86,    87,    88,    89,    90,    91,    92,    93,
      94,    95,    96,   307,    98,    99,   100,   105,   106,   107,
     108,   102,   110,    -1,   122,   113,   124,    -1,    -1,    -1,
     118,    -1,   130,   131,   132,   133,   134,   135,   136,   137,
     105,   106,   107,   108,   109,   110,    -1,    -1,   113,   114,
     115,   116,   117,   118,   105,   106,   107,   108,    -1,   110,
      -1,    -1,   113,   114,   115,   116,    -1,   118,   105,   106,
     107,   108,    -1,   110,    -1,    -1,   113,   114,   115,   116,
      -1,   118,   105,   106,   107,   108,    -1,   110,    -1,    -1,
     113,   114,   115,   116,    -1,   118,   105,   106,   107,   108,
      -1,   110,    -1,    -1,   113,   114,   115,   116,    -1,   118,
     105,   106,   107,   108,    -1,   110,    -1,    -1,   113,   114,
     115,   116,    -1,   118,   105,   106,   107,   108,    -1,   110,
      -1,    -1,   113,   105,   106,   107,   108,   118,   110,    -1,
      -1,   113,    -1,    -1,    -1,    -1,   118
};

/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
   symbol of state STATE-NUM.  */
static const yytype_uint16 yystos[] =
{
       0,     4,     6,     7,     8,     9,    25,    27,    31,    97,
     103,   111,   140,   141,   142,   143,   144,   146,   147,   159,
     162,   164,   113,   113,   114,   113,   124,   163,   165,   148,
     113,   160,     4,     0,   142,     4,   123,    72,     4,   125,
     257,   258,     4,   109,   113,   116,   117,   252,   253,    52,
      53,    54,    55,   223,     4,    31,   102,   111,   119,   120,
     143,   149,   153,   154,   161,   162,   212,   213,   214,   113,
     113,   125,   105,   106,   107,   108,   110,   113,   114,   115,
     116,   118,   248,   256,   261,   262,   263,   264,   166,   109,
     150,   151,     4,   154,   104,    14,    30,    78,   155,   156,
     214,     4,   138,    86,    87,    88,    89,    90,    91,    92,
      93,    94,    95,    96,    98,    99,   100,   172,   173,   174,
     175,   176,   177,   178,   186,   187,   188,   123,   114,   113,
     256,   113,   157,     4,   117,   262,   126,   126,   126,   126,
     126,   126,   126,     4,   188,   264,   109,   117,   254,   255,
     256,   255,    72,   186,   124,   158,   248,   249,   250,   251,
     255,   113,   116,   152,   109,   113,    52,    53,    54,    55,
     109,   113,   124,   179,   180,   113,   113,   152,   152,   167,
     123,   123,   110,   102,   259,   260,   124,    72,   127,   127,
     127,   257,    72,   127,   127,   127,   127,   127,     4,   168,
     152,   152,   125,   261,   257,   251,   125,   180,     5,    32,
     111,   119,   120,   144,   145,   169,   181,   209,   210,   211,
     125,   170,   113,     4,     4,    73,   211,     1,   212,   215,
     171,   223,    72,     4,    10,    12,    13,    14,    29,    30,
      31,    35,    64,    65,    66,    67,    75,    79,    81,   109,
     113,   116,   117,   126,   149,   182,   197,   199,   205,   207,
     219,   225,   229,   231,   233,   234,   235,   243,   244,   245,
     248,   109,   264,   254,    14,   256,    14,   256,   256,   220,
     113,   221,   222,   235,   248,   230,     4,     4,     4,   249,
     226,   126,     4,   236,    36,    37,    38,    39,    40,    41,
      42,    43,    45,    46,    47,    48,    49,   121,   123,   124,
     232,   195,   256,    10,    57,    58,    59,    60,    61,    62,
      72,   246,   247,   256,   246,   247,   223,    72,   223,   223,
     126,   183,   198,   200,   113,   241,   242,   248,   206,   126,
     113,   248,   253,    14,   113,   116,   117,   128,   129,   130,
     131,   227,   235,   248,   256,   257,   256,    18,    19,    20,
      21,   101,   196,    10,   254,   256,    10,   254,   256,   109,
     216,   217,   248,   109,   109,   242,   190,   201,   202,    22,
      72,   127,   195,   113,   208,   238,   256,   113,   237,   238,
     158,   109,   224,   256,    44,    50,    51,    56,    57,    58,
      59,    60,    61,    62,    68,    69,    70,    71,   122,   124,
     130,   131,   132,   133,   134,   135,   136,   137,   228,   125,
     126,   254,    10,   254,    10,   101,   218,    72,   123,   123,
     127,    11,    85,   185,   191,     4,    15,    80,   203,     4,
      16,    82,   204,   248,   113,   241,   123,    22,    72,   127,
     239,    22,    72,   127,   124,   257,   256,   123,   113,   254,
     254,   217,   264,   264,   238,   256,    77,    83,    84,   189,
       4,   256,     4,   256,     4,    22,   234,   256,   113,   238,
      17,    21,   240,   256,   113,   238,   257,   125,   256,   127,
       4,   256,   256,   113,   248,   184,   214,   239,   239,   248,
     126,    22,   126,    22,   125,     4,    72,     4,     4,    72,
       4,    72,   192,     4,   237,   256,   113,   256,   256,   256,
     256,    29,    63,    76,   193,   127,   127,     4,     4,     4,
     194,   248,     4,   223,   195,   217
};

#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


/* Like YYERROR except do call yyerror.  This remains here temporarily
   to ease the transition to the new meaning of YYERROR, for GCC.
   Once GCC version 2 has supplanted version 1, this can go.  */

#define YYFAIL		goto yyerrlab

#define YYRECOVERING()  (!!yyerrstatus)

#define YYBACKUP(Token, Value)					\
do								\
  if (yychar == YYEMPTY && yylen == 1)				\
    {								\
      yychar = (Token);						\
      yylval = (Value);						\
      yytoken = YYTRANSLATE (yychar);				\
      YYPOPSTACK (1);						\
      goto yybackup;						\
    }								\
  else								\
    {								\
      yyerror (yyscanner, interp, YY_("syntax error: cannot back up")); \
      YYERROR;							\
    }								\
while (YYID (0))


#define YYTERROR	1
#define YYERRCODE	256


/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
   If N is 0, then set CURRENT to the empty location which ends
   the previous symbol: RHS[0] (always defined).  */

#define YYRHSLOC(Rhs, K) ((Rhs)[K])
#ifndef YYLLOC_DEFAULT
# define YYLLOC_DEFAULT(Current, Rhs, N)				\
    do									\
      if (YYID (N))                                                    \
	{								\
	  (Current).first_line   = YYRHSLOC (Rhs, 1).first_line;	\
	  (Current).first_column = YYRHSLOC (Rhs, 1).first_column;	\
	  (Current).last_line    = YYRHSLOC (Rhs, N).last_line;		\
	  (Current).last_column  = YYRHSLOC (Rhs, N).last_column;	\
	}								\
      else								\
	{								\
	  (Current).first_line   = (Current).last_line   =		\
	    YYRHSLOC (Rhs, 0).last_line;				\
	  (Current).first_column = (Current).last_column =		\
	    YYRHSLOC (Rhs, 0).last_column;				\
	}								\
    while (YYID (0))
#endif


/* YY_LOCATION_PRINT -- Print the location on the stream.
   This macro was not mandated originally: define only if we know
   we won't break user code: when these are the locations we know.  */

#ifndef YY_LOCATION_PRINT
# if YYLTYPE_IS_TRIVIAL
#  define YY_LOCATION_PRINT(File, Loc)			\
     fprintf (File, "%d.%d-%d.%d",			\
	      (Loc).first_line, (Loc).first_column,	\
	      (Loc).last_line,  (Loc).last_column)
# else
#  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
# endif
#endif


/* YYLEX -- calling `yylex' with the right arguments.  */

#ifdef YYLEX_PARAM
# define YYLEX yylex (&yylval, YYLEX_PARAM)
#else
# define YYLEX yylex (&yylval, yyscanner, interp)
#endif

/* Enable debugging if requested.  */
#if YYDEBUG

# ifndef YYFPRINTF
#  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
#  define YYFPRINTF fprintf
# endif

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

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


/*--------------------------------.
| Print this symbol on YYOUTPUT.  |
`--------------------------------*/

/*ARGSUSED*/
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static void
yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *yyscanner, Parrot_Interp interp)
#else
static void
yy_symbol_value_print (yyoutput, yytype, yyvaluep, yyscanner, interp)
    FILE *yyoutput;
    int yytype;
    YYSTYPE const * const yyvaluep;
    void *yyscanner;
    Parrot_Interp interp;
#endif
{
  if (!yyvaluep)
    return;
  YYUSE (yyscanner);
  YYUSE (interp);
# ifdef YYPRINT
  if (yytype < YYNTOKENS)
    YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
# else
  YYUSE (yyoutput);
# endif
  switch (yytype)
    {
      default:
	break;
    }
}


/*--------------------------------.
| Print this symbol on YYOUTPUT.  |
`--------------------------------*/

#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static void
yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, void *yyscanner, Parrot_Interp interp)
#else
static void
yy_symbol_print (yyoutput, yytype, yyvaluep, yyscanner, interp)
    FILE *yyoutput;
    int yytype;
    YYSTYPE const * const yyvaluep;
    void *yyscanner;
    Parrot_Interp interp;
#endif
{
  if (yytype < YYNTOKENS)
    YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
  else
    YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);

  yy_symbol_value_print (yyoutput, yytype, yyvaluep, yyscanner, interp);
  YYFPRINTF (yyoutput, ")");
}

/*------------------------------------------------------------------.
| yy_stack_print -- Print the state stack from its BOTTOM up to its |
| TOP (included).                                                   |
`------------------------------------------------------------------*/

#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static void
yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
#else
static void
yy_stack_print (bottom, top)
    yytype_int16 *bottom;
    yytype_int16 *top;
#endif
{
  YYFPRINTF (stderr, "Stack now");
  for (; bottom <= top; ++bottom)
    YYFPRINTF (stderr, " %d", *bottom);
  YYFPRINTF (stderr, "\n");
}

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


/*------------------------------------------------.
| Report that the YYRULE is going to be reduced.  |
`------------------------------------------------*/

#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static void
yy_reduce_print (YYSTYPE *yyvsp, int yyrule, void *yyscanner, Parrot_Interp interp)
#else
static void
yy_reduce_print (yyvsp, yyrule, yyscanner, interp)
    YYSTYPE *yyvsp;
    int yyrule;
    void *yyscanner;
    Parrot_Interp interp;
#endif
{
  int yynrhs = yyr2[yyrule];
  int yyi;
  unsigned long int yylno = yyrline[yyrule];
  YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
	     yyrule - 1, yylno);
  /* The symbols being reduced.  */
  for (yyi = 0; yyi < yynrhs; yyi++)
    {
      fprintf (stderr, "   $%d = ", yyi + 1);
      yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
		       &(yyvsp[(yyi + 1) - (yynrhs)])
		       		       , yyscanner, interp);
      fprintf (stderr, "\n");
    }
}

# define YY_REDUCE_PRINT(Rule)		\
do {					\
  if (yydebug)				\
    yy_reduce_print (yyvsp, Rule, yyscanner, interp); \
} while (YYID (0))

/* Nonzero means print parse trace.  It is left uninitialized so that
   multiple parsers can coexist.  */
int yydebug;
#else /* !YYDEBUG */
# define YYDPRINTF(Args)
# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
# define YY_STACK_PRINT(Bottom, Top)
# define YY_REDUCE_PRINT(Rule)
#endif /* !YYDEBUG */


/* YYINITDEPTH -- initial size of the parser's stacks.  */
#ifndef	YYINITDEPTH
# define YYINITDEPTH 200
#endif

/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
   if the built-in stack extension method is used).

   Do not make this value too large; the results are undefined if
   YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
   evaluated with infinite-precision integer arithmetic.  */

#ifndef YYMAXDEPTH
# define YYMAXDEPTH 10000
#endif



#if YYERROR_VERBOSE

# ifndef yystrlen
#  if defined __GLIBC__ && defined _STRING_H
#   define yystrlen strlen
#  else
/* Return the length of YYSTR.  */
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static YYSIZE_T
yystrlen (const char *yystr)
#else
static YYSIZE_T
yystrlen (yystr)
    const char *yystr;
#endif
{
  YYSIZE_T yylen;
  for (yylen = 0; yystr[yylen]; yylen++)
    continue;
  return yylen;
}
#  endif
# endif

# ifndef yystpcpy
#  if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
#   define yystpcpy stpcpy
#  else
/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
   YYDEST.  */
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static char *
yystpcpy (char *yydest, const char *yysrc)
#else
static char *
yystpcpy (yydest, yysrc)
    char *yydest;
    const char *yysrc;
#endif
{
  char *yyd = yydest;
  const char *yys = yysrc;

  while ((*yyd++ = *yys++) != '\0')
    continue;

  return yyd - 1;
}
#  endif
# endif

# ifndef yytnamerr
/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
   quotes and backslashes, so that it's suitable for yyerror.  The
   heuristic is that double-quoting is unnecessary unless the string
   contains an apostrophe, a comma, or backslash (other than
   backslash-backslash).  YYSTR is taken from yytname.  If YYRES is
   null, do not copy; instead, return the length of what the result
   would have been.  */
static YYSIZE_T
yytnamerr (char *yyres, const char *yystr)
{
  if (*yystr == '"')
    {
      YYSIZE_T yyn = 0;
      char const *yyp = yystr;

      for (;;)
	switch (*++yyp)
	  {
	  case '\'':
	  case ',':
	    goto do_not_strip_quotes;

	  case '\\':
	    if (*++yyp != '\\')
	      goto do_not_strip_quotes;
	    /* Fall through.  */
	  default:
	    if (yyres)
	      yyres[yyn] = *yyp;
	    yyn++;
	    break;

	  case '"':
	    if (yyres)
	      yyres[yyn] = '\0';
	    return yyn;
	  }
    do_not_strip_quotes: ;
    }

  if (! yyres)
    return yystrlen (yystr);

  return yystpcpy (yyres, yystr) - yyres;
}
# endif

/* Copy into YYRESULT an error message about the unexpected token
   YYCHAR while in state YYSTATE.  Return the number of bytes copied,
   including the terminating null byte.  If YYRESULT is null, do not
   copy anything; just return the number of bytes that would be
   copied.  As a special case, return 0 if an ordinary "syntax error"
   message will do.  Return YYSIZE_MAXIMUM if overflow occurs during
   size calculation.  */
static YYSIZE_T
yysyntax_error (char *yyresult, int yystate, int yychar)
{
  int yyn = yypact[yystate];

  if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
    return 0;
  else
    {
      int yytype = YYTRANSLATE (yychar);
      YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
      YYSIZE_T yysize = yysize0;
      YYSIZE_T yysize1;
      int yysize_overflow = 0;
      enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
      char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
      int yyx;

# if 0
      /* This is so xgettext sees the translatable formats that are
	 constructed on the fly.  */
      YY_("syntax error, unexpected %s");
      YY_("syntax error, unexpected %s, expecting %s");
      YY_("syntax error, unexpected %s, expecting %s or %s");
      YY_("syntax error, unexpected %s, expecting %s or %s or %s");
      YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
# endif
      char *yyfmt;
      char const *yyf;
      static char const yyunexpected[] = "syntax error, unexpected %s";
      static char const yyexpecting[] = ", expecting %s";
      static char const yyor[] = " or %s";
      char yyformat[sizeof yyunexpected
		    + sizeof yyexpecting - 1
		    + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
		       * (sizeof yyor - 1))];
      char const *yyprefix = yyexpecting;

      /* Start YYX at -YYN if negative to avoid negative indexes in
	 YYCHECK.  */
      int yyxbegin = yyn < 0 ? -yyn : 0;

      /* Stay within bounds of both yycheck and yytname.  */
      int yychecklim = YYLAST - yyn + 1;
      int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
      int yycount = 1;

      yyarg[0] = yytname[yytype];
      yyfmt = yystpcpy (yyformat, yyunexpected);

      for (yyx = yyxbegin; yyx < yyxend; ++yyx)
	if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
	  {
	    if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
	      {
		yycount = 1;
		yysize = yysize0;
		yyformat[sizeof yyunexpected - 1] = '\0';
		break;
	      }
	    yyarg[yycount++] = yytname[yyx];
	    yysize1 = yysize + yytnamerr (0, yytname[yyx]);
	    yysize_overflow |= (yysize1 < yysize);
	    yysize = yysize1;
	    yyfmt = yystpcpy (yyfmt, yyprefix);
	    yyprefix = yyor;
	  }

      yyf = YY_(yyformat);
      yysize1 = yysize + yystrlen (yyf);
      yysize_overflow |= (yysize1 < yysize);
      yysize = yysize1;

      if (yysize_overflow)
	return YYSIZE_MAXIMUM;

      if (yyresult)
	{
	  /* Avoid sprintf, as that infringes on the user's name space.
	     Don't have undefined behavior even if the translation
	     produced a string with the wrong number of "%s"s.  */
	  char *yyp = yyresult;
	  int yyi = 0;
	  while ((*yyp = *yyf) != '\0')
	    {
	      if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
		{
		  yyp += yytnamerr (yyp, yyarg[yyi++]);
		  yyf += 2;
		}
	      else
		{
		  yyp++;
		  yyf++;
		}
	    }
	}
      return yysize;
    }
}
#endif /* YYERROR_VERBOSE */


/*-----------------------------------------------.
| Release the memory associated to this symbol.  |
`-----------------------------------------------*/

/*ARGSUSED*/
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static void
yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, void *yyscanner, Parrot_Interp interp)
#else
static void
yydestruct (yymsg, yytype, yyvaluep, yyscanner, interp)
    const char *yymsg;
    int yytype;
    YYSTYPE *yyvaluep;
    void *yyscanner;
    Parrot_Interp interp;
#endif
{
  YYUSE (yyvaluep);
  YYUSE (yyscanner);
  YYUSE (interp);

  if (!yymsg)
    yymsg = "Deleting";
  YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);

  switch (yytype)
    {

      default:
	break;
    }
}


/* Prevent warnings from -Wmissing-prototypes.  */

#ifdef YYPARSE_PARAM
#if defined __STDC__ || defined __cplusplus
int yyparse (void *YYPARSE_PARAM);
#else
int yyparse ();
#endif
#else /* ! YYPARSE_PARAM */
#if defined __STDC__ || defined __cplusplus
int yyparse (void *yyscanner, Parrot_Interp interp);
#else
int yyparse ();
#endif
#endif /* ! YYPARSE_PARAM */






/*----------.
| yyparse.  |
`----------*/

#ifdef YYPARSE_PARAM
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
int
yyparse (void *YYPARSE_PARAM)
#else
int
yyparse (YYPARSE_PARAM)
    void *YYPARSE_PARAM;
#endif
#else /* ! YYPARSE_PARAM */
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
int
yyparse (void *yyscanner, Parrot_Interp interp)
#else
int
yyparse (yyscanner, interp)
    void *yyscanner;
    Parrot_Interp interp;
#endif
#endif
{
  /* The look-ahead symbol.  */
int yychar;

/* The semantic value of the look-ahead symbol.  */
YYSTYPE yylval;

/* Number of syntax errors so far.  */
int yynerrs;

  int yystate;
  int yyn;
  int yyresult;
  /* Number of tokens to shift before error messages enabled.  */
  int yyerrstatus;
  /* Look-ahead token as an internal (translated) token number.  */
  int yytoken = 0;
#if YYERROR_VERBOSE
  /* Buffer for error messages, and its allocated size.  */
  char yymsgbuf[128];
  char *yymsg = yymsgbuf;
  YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
#endif

  /* Three stacks and their tools:
     `yyss': related to states,
     `yyvs': related to semantic values,
     `yyls': related to locations.

     Refer to the stacks thru separate pointers, to allow yyoverflow
     to reallocate them elsewhere.  */

  /* The state stack.  */
  yytype_int16 yyssa[YYINITDEPTH];
  yytype_int16 *yyss = yyssa;
  yytype_int16 *yyssp;

  /* The semantic value stack.  */
  YYSTYPE yyvsa[YYINITDEPTH];
  YYSTYPE *yyvs = yyvsa;
  YYSTYPE *yyvsp;



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

  YYSIZE_T yystacksize = YYINITDEPTH;

  /* The variables used to return semantic value and location from the
     action routines.  */
  YYSTYPE yyval;


  /* The number of symbols on the RHS of the reduced rule.
     Keep to zero when no symbol should be popped.  */
  int yylen = 0;

  YYDPRINTF ((stderr, "Starting parse\n"));

  yystate = 0;
  yyerrstatus = 0;
  yynerrs = 0;
  yychar = YYEMPTY;		/* Cause a token to be read.  */

  /* Initialize stack pointers.
     Waste one element of value and location stack
     so that they stay on the same level as the state stack.
     The wasted elements are never initialized.  */

  yyssp = yyss;
  yyvsp = yyvs;

  goto yysetstate;

/*------------------------------------------------------------.
| yynewstate -- Push a new state, which is found in yystate.  |
`------------------------------------------------------------*/
 yynewstate:
  /* In all cases, when you get here, the value and location stacks
     have just been pushed.  So pushing a state here evens the stacks.  */
  yyssp++;

 yysetstate:
  *yyssp = yystate;

  if (yyss + yystacksize - 1 <= yyssp)
    {
      /* Get the current used size of the three stacks, in elements.  */
      YYSIZE_T yysize = yyssp - yyss + 1;

#ifdef yyoverflow
      {
	/* Give user a chance to reallocate the stack.  Use copies of
	   these so that the &'s don't force the real ones into
	   memory.  */
	YYSTYPE *yyvs1 = yyvs;
	yytype_int16 *yyss1 = yyss;


	/* Each stack pointer address is followed by the size of the
	   data in use in that stack, in bytes.  This used to be a
	   conditional around just the two extra args, but that might
	   be undefined if yyoverflow is a macro.  */
	yyoverflow (YY_("memory exhausted"),
		    &yyss1, yysize * sizeof (*yyssp),
		    &yyvs1, yysize * sizeof (*yyvsp),

		    &yystacksize);

	yyss = yyss1;
	yyvs = yyvs1;
      }
#else /* no yyoverflow */
# ifndef YYSTACK_RELOCATE
      goto yyexhaustedlab;
# else
      /* Extend the stack our own way.  */
      if (YYMAXDEPTH <= yystacksize)
	goto yyexhaustedlab;
      yystacksize *= 2;
      if (YYMAXDEPTH < yystacksize)
	yystacksize = YYMAXDEPTH;

      {
	yytype_int16 *yyss1 = yyss;
	union yyalloc *yyptr =
	  (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
	if (! yyptr)
	  goto yyexhaustedlab;
	YYSTACK_RELOCATE (yyss);
	YYSTACK_RELOCATE (yyvs);

#  undef YYSTACK_RELOCATE
	if (yyss1 != yyssa)
	  YYSTACK_FREE (yyss1);
      }
# endif
#endif /* no yyoverflow */

      yyssp = yyss + yysize - 1;
      yyvsp = yyvs + yysize - 1;


      YYDPRINTF ((stderr, "Stack size increased to %lu\n",
		  (unsigned long int) yystacksize));

      if (yyss + yystacksize - 1 <= yyssp)
	YYABORT;
    }

  YYDPRINTF ((stderr, "Entering state %d\n", yystate));

  goto yybackup;

/*-----------.
| yybackup.  |
`-----------*/
yybackup:

  /* Do appropriate processing given the current state.  Read a
     look-ahead token if we need one and don't already have one.  */

  /* First try to decide what to do without reference to look-ahead token.  */
  yyn = yypact[yystate];
  if (yyn == YYPACT_NINF)
    goto yydefault;

  /* Not known => get a look-ahead token if don't already have one.  */

  /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol.  */
  if (yychar == YYEMPTY)
    {
      YYDPRINTF ((stderr, "Reading a token: "));
      yychar = YYLEX;
    }

  if (yychar <= YYEOF)
    {
      yychar = yytoken = YYEOF;
      YYDPRINTF ((stderr, "Now at end of input.\n"));
    }
  else
    {
      yytoken = YYTRANSLATE (yychar);
      YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
    }

  /* If the proper action on seeing token YYTOKEN is to reduce or to
     detect an error, take that action.  */
  yyn += yytoken;
  if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
    goto yydefault;
  yyn = yytable[yyn];
  if (yyn <= 0)
    {
      if (yyn == 0 || yyn == YYTABLE_NINF)
	goto yyerrlab;
      yyn = -yyn;
      goto yyreduce;
    }

  if (yyn == YYFINAL)
    YYACCEPT;

  /* Count tokens shifted since error; after three, turn off error
     status.  */
  if (yyerrstatus)
    yyerrstatus--;

  /* Shift the look-ahead token.  */
  YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);

  /* Discard the shifted token unless it is eof.  */
  if (yychar != YYEOF)
    yychar = YYEMPTY;

  yystate = yyn;
  *++yyvsp = yylval;

  goto yynewstate;


/*-----------------------------------------------------------.
| yydefault -- do the default action for the current state.  |
`-----------------------------------------------------------*/
yydefault:
  yyn = yydefact[yystate];
  if (yyn == 0)
    goto yyerrlab;
  goto yyreduce;


/*-----------------------------.
| yyreduce -- Do a reduction.  |
`-----------------------------*/
yyreduce:
  /* yyn is the number of a rule to reduce with.  */
  yylen = yyr2[yyn];

  /* If YYLEN is nonzero, implement the default value of the action:
     `$$ = $1'.

     Otherwise, the following line sets YYVAL to garbage.
     This behavior is undocumented and Bison
     users should not rely upon it.  Assigning to YYVAL
     unconditionally makes the parser a bit smaller, and it avoids a
     GCC warning that YYVAL may be used uninitialized.  */
  yyval = yyvsp[1-yylen];


  YY_REDUCE_PRINT (yyn);
  switch (yyn)
    {
        case 2:
#line 880 "compilers/imcc/imcc.y"
    { if (yynerrs) YYABORT; (yyval.i) = 0; }
    break;

  case 5:
#line 889 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 6:
#line 890 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 7:
#line 892 "compilers/imcc/imcc.y"
    {
           (yyval.i) = (yyvsp[(1) - (1)].i);
           imc_close_unit(interp, IMCC_INFO(interp)->cur_unit);
           IMCC_INFO(interp)->cur_unit = 0;
         }
    break;

  case 8:
#line 898 "compilers/imcc/imcc.y"
    {
           (yyval.i) = (yyvsp[(1) - (1)].i);
           imc_close_unit(interp, IMCC_INFO(interp)->cur_unit);
           IMCC_INFO(interp)->cur_unit = 0;
         }
    break;

  case 9:
#line 903 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 10:
#line 904 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 11:
#line 905 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 12:
#line 906 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 13:
#line 910 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 14:
#line 912 "compilers/imcc/imcc.y"
    {
           (yyval.i) = 0;
           do_loadlib(interp, (yyvsp[(2) - (3)].s));
           mem_sys_free((yyvsp[(2) - (3)].s));
         }
    break;

  case 15:
#line 921 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->line = atoi((yyvsp[(2) - (5)].s));
           set_filename(interp, (yyvsp[(4) - (5)].s));
         }
    break;

  case 16:
#line 926 "compilers/imcc/imcc.y"
    {
           set_filename(interp, (yyvsp[(2) - (3)].s));
         }
    break;

  case 17:
#line 933 "compilers/imcc/imcc.y"
    {
          /* We'll want to store an entry while emitting instructions, so just
           * store annotation like it's an instruction. */
          SymReg * const key = mk_const(interp, (yyvsp[(2) - (4)].s), 'S');
          (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, ".annotate", 2, key, (yyvsp[(4) - (4)].sr));
          mem_sys_free((yyvsp[(2) - (4)].s));
        }
    break;

  case 18:
#line 945 "compilers/imcc/imcc.y"
    {
            STRING * const hll_name = string_unescape_cstring(interp, (yyvsp[(2) - (2)].s) + 1, '"', NULL);
            CONTEXT(interp)->current_HLL =
                Parrot_register_HLL(interp, hll_name);

            IMCC_INFO(interp)->cur_namespace = NULL;
            (yyval.t) = 0;
         }
    break;

  case 19:
#line 954 "compilers/imcc/imcc.y"
    {
            Parrot_Context *ctx           = CONTEXT(interp);
            STRING * const  built_in_name =
                string_unescape_cstring(interp, (yyvsp[(2) - (4)].s) + 1, '"', NULL);
            STRING * const language_name  =
                string_unescape_cstring(interp, (yyvsp[(4) - (4)].s) + 1, '"', NULL);

            int             built_in_type = pmc_type(interp, built_in_name);
            int             language_type = pmc_type(interp, language_name);

            Parrot_register_HLL_type(interp, ctx->current_HLL,
                built_in_type, language_type);
            (yyval.t) = 0;
         }
    break;

  case 20:
#line 971 "compilers/imcc/imcc.y"
    { is_def = 1; }
    break;

  case 21:
#line 972 "compilers/imcc/imcc.y"
    {
             mk_const_ident(interp, (yyvsp[(4) - (6)].s), (yyvsp[(3) - (6)].t), (yyvsp[(6) - (6)].sr), 1);
             mem_sys_free((yyvsp[(4) - (6)].s));
             is_def = 0;
         }
    break;

  case 22:
#line 980 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 23:
#line 981 "compilers/imcc/imcc.y"
    {
           (yyval.i) = mk_pmc_const(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(3) - (6)].s), (yyvsp[(4) - (6)].sr), (yyvsp[(6) - (6)].s));
           is_def = 0;
         }
    break;

  case 24:
#line 986 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 25:
#line 987 "compilers/imcc/imcc.y"
    {
           (yyval.i) = mk_pmc_const_named(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(3) - (6)].s), (yyvsp[(4) - (6)].sr), (yyvsp[(6) - (6)].s));
           is_def = 0;
         }
    break;

  case 30:
#line 1003 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;  }
    break;

  case 31:
#line 1004 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;  }
    break;

  case 32:
#line 1005 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;  }
    break;

  case 33:
#line 1006 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;  }
    break;

  case 34:
#line 1007 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 37:
#line 1012 "compilers/imcc/imcc.y"
    { clear_state(interp); }
    break;

  case 38:
#line 1014 "compilers/imcc/imcc.y"
    {
           (yyval.i) = INS(interp, IMCC_INFO(interp)->cur_unit,
                    (yyvsp[(2) - (3)].s), 0, IMCC_INFO(interp)->regs,
                    IMCC_INFO(interp)->nargs, IMCC_INFO(interp) -> keyvec, 1);
            mem_sys_free((yyvsp[(2) - (3)].s));
         }
    break;

  case 39:
#line 1021 "compilers/imcc/imcc.y"
    {
           imc_close_unit(interp, IMCC_INFO(interp)->cur_unit);
           IMCC_INFO(interp)->cur_unit = imc_open_unit(interp, IMC_PASM);
         }
    break;

  case 40:
#line 1026 "compilers/imcc/imcc.y"
    {
           (yyval.i) = iSUBROUTINE(interp,
                    IMCC_INFO(interp)->cur_unit,
                    mk_sub_label(interp, (yyvsp[(4) - (4)].s)));
           IMCC_INFO(interp)->cur_call->pcc_sub->pragma = (yyvsp[(3) - (4)].t);
         }
    break;

  case 41:
#line 1033 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "null", 1, (yyvsp[(2) - (2)].sr));
         }
    break;

  case 42:
#line 1037 "compilers/imcc/imcc.y"
    {
           SymReg *r = mk_pasm_reg(interp, (yyvsp[(4) - (4)].s));
           set_lexical(interp, r, (yyvsp[(2) - (4)].s));
           (yyval.i) = 0;
           mem_sys_free((yyvsp[(2) - (4)].s));
           mem_sys_free((yyvsp[(4) - (4)].s));
         }
    break;

  case 43:
#line 1044 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;}
    break;

  case 45:
#line 1052 "compilers/imcc/imcc.y"
    { IMCC_INFO(interp)->cur_unit = imc_open_unit(interp, IMC_PASM); }
    break;

  case 46:
#line 1055 "compilers/imcc/imcc.y"
    {
           /* if (optimizer_level & OPT_PASM)
                         imc_compile_unit(interp, IMCC_INFO(interp)->cur_unit);
                         emit_flush(interp);
           */
           (yyval.i) = 0;
         }
    break;

  case 49:
#line 1071 "compilers/imcc/imcc.y"
    {
           int re_open = 0;
           (yyval.i) = 0;
           if (IMCC_INFO(interp)->state->pasm_file && IMCC_INFO(interp)->cur_namespace) {
               imc_close_unit(interp, IMCC_INFO(interp)->cur_unit);
               re_open = 1;
           }
           IMCC_INFO(interp)->cur_namespace = (yyvsp[(2) - (3)].sr);
           if (re_open)
               IMCC_INFO(interp)->cur_unit = imc_open_unit(interp, IMC_PASM);
         }
    break;

  case 50:
#line 1086 "compilers/imcc/imcc.y"
    {
            if (IMCC_INFO(interp)->in_slice)
                IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                    "Slice not allowed in namespace.");

            (yyval.sr) = (yyvsp[(2) - (3)].sr);
        }
    break;

  case 51:
#line 1093 "compilers/imcc/imcc.y"
    { (yyval.sr) = NULL; }
    break;

  case 52:
#line 1098 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->cur_unit = imc_open_unit(interp, IMC_PCCSUB);
         }
    break;

  case 53:
#line 1102 "compilers/imcc/imcc.y"
    {
           iSUBROUTINE(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(3) - (3)].sr));
         }
    break;

  case 54:
#line 1106 "compilers/imcc/imcc.y"
    {
          IMCC_INFO(interp)->cur_call->pcc_sub->pragma = (yyvsp[(5) - (6)].t);
          if (!IMCC_INFO(interp)->cur_unit->instructions->symregs[0]->subid) {
            IMCC_INFO(interp)->cur_unit->instructions->symregs[0]->subid = str_dup(
            IMCC_INFO(interp)->cur_unit->instructions->symregs[0]->name);
          }
        }
    break;

  case 55:
#line 1114 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; IMCC_INFO(interp)->cur_call = NULL; }
    break;

  case 56:
#line 1118 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 57:
#line 1119 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 58:
#line 1121 "compilers/imcc/imcc.y"
    {
           if (IMCC_INFO(interp)->adv_named_id) {
                 add_pcc_named_param(interp, IMCC_INFO(interp)->cur_call,
                                     IMCC_INFO(interp)->adv_named_id, (yyvsp[(2) - (3)].sr));
                 IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_arg(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 59:
#line 1133 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 60:
#line 1133 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(3) - (3)].sr); is_def=0; }
    break;

  case 61:
#line 1138 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(3) - (3)].t) & VT_UNIQUE_REG)
               (yyval.sr) = mk_ident_ur(interp, (yyvsp[(2) - (3)].s), (yyvsp[(1) - (3)].t));
           else
               (yyval.sr) = mk_ident(interp, (yyvsp[(2) - (3)].s), (yyvsp[(1) - (3)].t));
           (yyval.sr)->type |= (yyvsp[(3) - (3)].t);
           mem_sys_free((yyvsp[(2) - (3)].s));
          }
    break;

  case 62:
#line 1151 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 63:
#line 1156 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->outer = mk_sub_address_fromc(interp, (yyvsp[(3) - (4)].s));
           mem_sys_free((yyvsp[(3) - (4)].s));
         }
    break;

  case 64:
#line 1162 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->outer = mk_const(interp, (yyvsp[(3) - (4)].s), 'S');
           mem_sys_free((yyvsp[(3) - (4)].s));
         }
    break;

  case 65:
#line 1171 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->vtable_name = NULL;
           IMCC_INFO(interp)->cur_unit->is_vtable_method = 1;
         }
    break;

  case 66:
#line 1177 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->vtable_name = (yyvsp[(3) - (4)].s);
           IMCC_INFO(interp)->cur_unit->is_vtable_method = 1;
         }
    break;

  case 67:
#line 1186 "compilers/imcc/imcc.y"
    {
           (yyval.t) = P_METHOD;
           IMCC_INFO(interp)->cur_unit->method_name = NULL;
           IMCC_INFO(interp)->cur_unit->is_method = 1;
         }
    break;

  case 68:
#line 1192 "compilers/imcc/imcc.y"
    {
           (yyval.t) = P_METHOD;
           IMCC_INFO(interp)->cur_unit->method_name = (yyvsp[(3) - (4)].s);
           IMCC_INFO(interp)->cur_unit->is_method = 1;
         }
    break;

  case 69:
#line 1201 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->ns_entry_name = NULL;
           IMCC_INFO(interp)->cur_unit->has_ns_entry_name = 1;
         }
    break;

  case 70:
#line 1207 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->ns_entry_name = (yyvsp[(3) - (4)].s);
           IMCC_INFO(interp)->cur_unit->has_ns_entry_name = 1;
         }
    break;

  case 71:
#line 1216 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->instance_of = (yyvsp[(3) - (4)].s);
         }
    break;

  case 72:
#line 1224 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->subid = NULL;
         }
    break;

  case 73:
#line 1229 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           IMCC_INFO(interp)->cur_unit->subid = mk_const(interp, (yyvsp[(3) - (4)].s), 'S');
           IMCC_INFO(interp)->cur_unit->instructions->symregs[0]->subid = str_dup_remove_quotes((yyvsp[(3) - (4)].s));
           mem_sys_free((yyvsp[(3) - (4)].s));
         }
    break;

  case 74:
#line 1239 "compilers/imcc/imcc.y"
    {
           add_pcc_multi(IMCC_INFO(interp)->cur_call, NULL);
         }
    break;

  case 75:
#line 1243 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           add_pcc_multi(IMCC_INFO(interp)->cur_call, (yyvsp[(3) - (3)].sr));
         }
    break;

  case 76:
#line 1248 "compilers/imcc/imcc.y"
    {
           (yyval.t) = 0;
           add_pcc_multi(IMCC_INFO(interp)->cur_call, (yyvsp[(1) - (1)].sr));
         }
    break;

  case 77:
#line 1255 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, "INTVAL",   'S'); }
    break;

  case 78:
#line 1256 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, "FLOATVAL", 'S'); }
    break;

  case 79:
#line 1257 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, "PMC",      'S'); }
    break;

  case 80:
#line 1258 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, "STRING",   'S'); }
    break;

  case 81:
#line 1260 "compilers/imcc/imcc.y"
    {
           SymReg *r;
           if (strcmp((yyvsp[(1) - (1)].s), "_") != 0)
               r = mk_const(interp, (yyvsp[(1) - (1)].s), 'S');
           else {
               r = mk_const(interp, "PMC", 'S');
           }
           mem_sys_free((yyvsp[(1) - (1)].s));
           (yyval.sr) = r;
         }
    break;

  case 82:
#line 1271 "compilers/imcc/imcc.y"
    {
           SymReg *r;
           if (strcmp((yyvsp[(1) - (1)].s), "_") != 0)
               r = mk_const(interp, (yyvsp[(1) - (1)].s), 'S');
           else {
               r = mk_const(interp, "PMC", 'S');
           }
           mem_sys_free((yyvsp[(1) - (1)].s));
           (yyval.sr) = r;
         }
    break;

  case 83:
#line 1281 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(2) - (3)].sr); }
    break;

  case 86:
#line 1291 "compilers/imcc/imcc.y"
    {
           char name[128];
           SymReg *r, *r1;
           Instruction *i;

           snprintf(name, sizeof (name), "%cpcc_sub_call_%d",
                   IMCC_INTERNAL_CHAR, IMCC_INFO(interp)->cnr++);
           (yyval.sr) = r = mk_pcc_sub(interp, name, 0);
           /* this mid rule action has the semantic value of the
            * sub SymReg.
            * This is used below to append args & results
            */
           i = iLABEL(interp, IMCC_INFO(interp)->cur_unit, r);
           IMCC_INFO(interp)->cur_call = r;
           i->type = ITPCCSUB;
           /*
            * if we are inside a pcc_sub mark the sub as doing a
            * sub call; the sub is in r[0] of the first ins
            */
           r1 = IMCC_INFO(interp)->cur_unit->instructions->symregs[0];
           if (r1 && r1->pcc_sub)
               r1->pcc_sub->calls_a_sub |= 1;
         }
    break;

  case 87:
#line 1319 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; IMCC_INFO(interp)->cur_call = NULL; }
    break;

  case 88:
#line 1323 "compilers/imcc/imcc.y"
    { (yyval.i) = NULL; IMCC_INFO(interp)->cur_call->pcc_sub->label = 0; }
    break;

  case 89:
#line 1324 "compilers/imcc/imcc.y"
    { (yyval.i) = NULL; IMCC_INFO(interp)->cur_call->pcc_sub->label = 1; }
    break;

  case 90:
#line 1328 "compilers/imcc/imcc.y"
    { (yyval.i) = NULL; }
    break;

  case 91:
#line 1329 "compilers/imcc/imcc.y"
    { (yyval.i) = NULL;  IMCC_INFO(interp)->cur_call->pcc_sub->object = (yyvsp[(2) - (3)].sr); }
    break;

  case 92:
#line 1333 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 94:
#line 1338 "compilers/imcc/imcc.y"
    { (yyval.t) = (yyvsp[(1) - (1)].t); }
    break;

  case 95:
#line 1339 "compilers/imcc/imcc.y"
    { (yyval.t) = (yyvsp[(1) - (2)].t) | (yyvsp[(2) - (2)].t); }
    break;

  case 96:
#line 1343 "compilers/imcc/imcc.y"
    { (yyval.t) = P_LOAD; }
    break;

  case 97:
#line 1344 "compilers/imcc/imcc.y"
    { (yyval.t) = P_INIT; }
    break;

  case 98:
#line 1345 "compilers/imcc/imcc.y"
    { (yyval.t) = P_MAIN; }
    break;

  case 99:
#line 1346 "compilers/imcc/imcc.y"
    { (yyval.t) = P_IMMEDIATE; }
    break;

  case 100:
#line 1347 "compilers/imcc/imcc.y"
    { (yyval.t) = P_POSTCOMP; }
    break;

  case 101:
#line 1348 "compilers/imcc/imcc.y"
    { (yyval.t) = P_ANON; }
    break;

  case 102:
#line 1349 "compilers/imcc/imcc.y"
    { (yyval.t) = P_NEED_LEX; }
    break;

  case 110:
#line 1361 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (5)].sr));
           add_pcc_cc(IMCC_INFO(interp)->cur_call, (yyvsp[(4) - (5)].sr));
         }
    break;

  case 111:
#line 1366 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 112:
#line 1370 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr));
           IMCC_INFO(interp)->cur_call->pcc_sub->flags |= isNCI;
         }
    break;

  case 113:
#line 1375 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 114:
#line 1379 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, mk_const(interp, (yyvsp[(2) - (3)].s), 'S'));
         }
    break;

  case 115:
#line 1383 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (5)].sr));
           add_pcc_cc(IMCC_INFO(interp)->cur_call, (yyvsp[(4) - (5)].sr));
         }
    break;

  case 116:
#line 1388 "compilers/imcc/imcc.y"
    {
           add_pcc_sub(IMCC_INFO(interp)->cur_call, mk_const(interp, (yyvsp[(2) - (5)].s), 'S'));
           add_pcc_cc(IMCC_INFO(interp)->cur_call, (yyvsp[(4) - (5)].sr));
         }
    break;

  case 117:
#line 1396 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 118:
#line 1397 "compilers/imcc/imcc.y"
    { add_pcc_arg(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr)); }
    break;

  case 119:
#line 1401 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(2) - (2)].sr); }
    break;

  case 120:
#line 1406 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 121:
#line 1408 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(2) - (3)].sr))
               add_pcc_result(IMCC_INFO(interp)->cur_call, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 122:
#line 1415 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(2) - (3)].sr); (yyval.sr)->type |= (yyvsp[(3) - (3)].t); }
    break;

  case 123:
#line 1416 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 124:
#line 1417 "compilers/imcc/imcc.y"
    {
           IdList *l = (yyvsp[(4) - (4)].idlist);
           SymReg *ignored;
           if (l->unique_reg)
               ignored = mk_ident_ur(interp, l->id, (yyvsp[(3) - (4)].t));
           else
               ignored = mk_ident(interp, l->id, (yyvsp[(3) - (4)].t));
           UNUSED(ignored);
           is_def=0;
           (yyval.sr)=0;
         }
    break;

  case 125:
#line 1431 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 126:
#line 1432 "compilers/imcc/imcc.y"
    { (yyval.t) = (yyvsp[(1) - (2)].t) | (yyvsp[(2) - (2)].t); }
    break;

  case 127:
#line 1436 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_FLAT;   }
    break;

  case 128:
#line 1437 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_OPTIONAL; }
    break;

  case 129:
#line 1438 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_OPT_FLAG; }
    break;

  case 130:
#line 1439 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_NAMED; }
    break;

  case 131:
#line 1440 "compilers/imcc/imcc.y"
    { adv_named_set(interp, (yyvsp[(3) - (4)].s)); (yyval.t) = 0; }
    break;

  case 132:
#line 1441 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_UNIQUE_REG; }
    break;

  case 133:
#line 1446 "compilers/imcc/imcc.y"
    { begin_return_or_yield(interp, 0); }
    break;

  case 134:
#line 1448 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; IMCC_INFO(interp)->asm_state = AsmDefault; }
    break;

  case 135:
#line 1450 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->asm_state = AsmDefault;
           (yyval.i) = 0;
         }
    break;

  case 136:
#line 1457 "compilers/imcc/imcc.y"
    { begin_return_or_yield(interp, 1); }
    break;

  case 137:
#line 1459 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; IMCC_INFO(interp)->asm_state = AsmDefault; }
    break;

  case 138:
#line 1463 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 139:
#line 1465 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(1) - (2)].sr))
               add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(1) - (2)].sr));
         }
    break;

  case 140:
#line 1470 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(2) - (3)].sr))
               add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 141:
#line 1477 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 142:
#line 1479 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(1) - (2)].sr))
               add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(1) - (2)].sr));
         }
    break;

  case 143:
#line 1484 "compilers/imcc/imcc.y"
    {
           if ((yyvsp[(2) - (3)].sr))
               add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(2) - (3)].sr));
         }
    break;

  case 144:
#line 1491 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(2) - (3)].sr); (yyval.sr)->type |= (yyvsp[(3) - (3)].t); }
    break;

  case 145:
#line 1495 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(2) - (3)].sr); (yyval.sr)->type |= (yyvsp[(3) - (3)].t); }
    break;

  case 146:
#line 1500 "compilers/imcc/imcc.y"
    {
          if (IMCC_INFO(interp)->asm_state == AsmDefault)
              begin_return_or_yield(interp, (yyvsp[(1) - (2)].t));
        }
    break;

  case 147:
#line 1505 "compilers/imcc/imcc.y"
    {
          IMCC_INFO(interp)->asm_state = AsmDefault;
          (yyval.t) = 0;
        }
    break;

  case 148:
#line 1512 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 149:
#line 1513 "compilers/imcc/imcc.y"
    { (yyval.t) = 1; }
    break;

  case 150:
#line 1517 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 151:
#line 1519 "compilers/imcc/imcc.y"
    {
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_return(interp, IMCC_INFO(interp)->sr_return,
                                    IMCC_INFO(interp)->adv_named_id, (yyvsp[(1) - (1)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(1) - (1)].sr));
         }
    break;

  case 152:
#line 1529 "compilers/imcc/imcc.y"
    {
           add_pcc_named_return(interp, IMCC_INFO(interp)->sr_return, (yyvsp[(1) - (3)].s), (yyvsp[(3) - (3)].sr));
         }
    break;

  case 153:
#line 1533 "compilers/imcc/imcc.y"
    {
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_return(interp, IMCC_INFO(interp)->sr_return,
                                    IMCC_INFO(interp)->adv_named_id, (yyvsp[(3) - (3)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
             }
             else
                 add_pcc_result(IMCC_INFO(interp)->sr_return, (yyvsp[(3) - (3)].sr));
         }
    break;

  case 154:
#line 1543 "compilers/imcc/imcc.y"
    {
           add_pcc_named_return(interp, IMCC_INFO(interp)->sr_return, (yyvsp[(3) - (5)].s), (yyvsp[(5) - (5)].sr));
         }
    break;

  case 157:
#line 1563 "compilers/imcc/imcc.y"
    { clear_state(interp); }
    break;

  case 158:
#line 1568 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(2) - (2)].i); }
    break;

  case 159:
#line 1569 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 160:
#line 1570 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 161:
#line 1571 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 162:
#line 1572 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 163:
#line 1573 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 164:
#line 1577 "compilers/imcc/imcc.y"
    { (yyval.i) = NULL; }
    break;

  case 168:
#line 1588 "compilers/imcc/imcc.y"
    {
           (yyval.i) = iLABEL(interp, IMCC_INFO(interp)->cur_unit, mk_local_label(interp, (yyvsp[(1) - (1)].s)));
         }
    break;

  case 169:
#line 1596 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(2) - (3)].i); }
    break;

  case 170:
#line 1598 "compilers/imcc/imcc.y"
    {
           if (yynerrs >= PARROT_MAX_RECOVER_ERRORS) {
               IMCC_warning(interp, "Too many errors. Correct some first.\n");
               YYABORT;
           }
           yyerrok;
         }
    break;

  case 171:
#line 1609 "compilers/imcc/imcc.y"
    {
           IdList* l = (yyvsp[(1) - (1)].idlist);
           l->next = NULL;
           (yyval.idlist) = l;
         }
    break;

  case 172:
#line 1616 "compilers/imcc/imcc.y"
    {
           IdList* l = (yyvsp[(3) - (3)].idlist);
           l->next = (yyvsp[(1) - (3)].idlist);
           (yyval.idlist) = l;
         }
    break;

  case 173:
#line 1625 "compilers/imcc/imcc.y"
    {
           IdList* const l = mem_allocate_n_zeroed_typed(1, IdList);
           l->id           = (yyvsp[(1) - (2)].s);
           l->unique_reg   = (yyvsp[(2) - (2)].t);
           (yyval.idlist) = l;
         }
    break;

  case 174:
#line 1634 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 175:
#line 1635 "compilers/imcc/imcc.y"
    { (yyval.t) = 1; }
    break;

  case 178:
#line 1642 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 179:
#line 1643 "compilers/imcc/imcc.y"
    {
           IdList *l = (yyvsp[(4) - (4)].idlist);
           while (l) {
               IdList *l1;
               if (l->unique_reg)
                   mk_ident_ur(interp, l->id, (yyvsp[(3) - (4)].t));
               else
                   mk_ident(interp, l->id, (yyvsp[(3) - (4)].t));
               l1 = l;
               l  = l->next;
               mem_sys_free(l1->id);
               mem_sys_free(l1);
           }
           is_def=0; (yyval.i)=0;
         }
    break;

  case 180:
#line 1659 "compilers/imcc/imcc.y"
    {
           set_lexical(interp, (yyvsp[(4) - (4)].sr), (yyvsp[(2) - (4)].s)); (yyval.i) = 0;
         }
    break;

  case 181:
#line 1662 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 182:
#line 1663 "compilers/imcc/imcc.y"
    {
           mk_const_ident(interp, (yyvsp[(4) - (6)].s), (yyvsp[(3) - (6)].t), (yyvsp[(6) - (6)].sr), 0);
           is_def=0;
           mem_sys_free((yyvsp[(4) - (6)].s));
         }
    break;

  case 184:
#line 1670 "compilers/imcc/imcc.y"
    { is_def=1; }
    break;

  case 185:
#line 1671 "compilers/imcc/imcc.y"
    {
           mk_const_ident(interp, (yyvsp[(4) - (6)].s), (yyvsp[(3) - (6)].t), (yyvsp[(6) - (6)].sr), 1);
           is_def=0;
           mem_sys_free((yyvsp[(4) - (6)].s));
         }
    break;

  case 186:
#line 1677 "compilers/imcc/imcc.y"
    {
           (yyval.i) = NULL;
           IMCC_INFO(interp)->cur_call->pcc_sub->flags |= isTAIL_CALL;
           IMCC_INFO(interp)->cur_call = NULL;
         }
    break;

  case 187:
#line 1682 "compilers/imcc/imcc.y"
    { (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "branch", 1, (yyvsp[(2) - (2)].sr)); }
    break;

  case 188:
#line 1684 "compilers/imcc/imcc.y"
    {
           (yyval.i) = INS(interp,
                    IMCC_INFO(interp)->cur_unit,
                    (yyvsp[(1) - (2)].s),
                    0,
                    IMCC_INFO(interp)->regs,
                    IMCC_INFO(interp)->nargs,
                    IMCC_INFO(interp)->keyvec,
                    1);
           mem_sys_free((yyvsp[(1) - (2)].s));
         }
    break;

  case 189:
#line 1695 "compilers/imcc/imcc.y"
    { (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "null", 1, (yyvsp[(2) - (2)].sr)); }
    break;

  case 190:
#line 1696 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; IMCC_INFO(interp)->cur_call = NULL; }
    break;

  case 191:
#line 1697 "compilers/imcc/imcc.y"
    { (yyval.i) = 0; }
    break;

  case 194:
#line 1700 "compilers/imcc/imcc.y"
    { (yyval.i) = 0;}
    break;

  case 195:
#line 1704 "compilers/imcc/imcc.y"
    { (yyval.t) = 'I'; }
    break;

  case 196:
#line 1705 "compilers/imcc/imcc.y"
    { (yyval.t) = 'N'; }
    break;

  case 197:
#line 1706 "compilers/imcc/imcc.y"
    { (yyval.t) = 'S'; }
    break;

  case 198:
#line 1707 "compilers/imcc/imcc.y"
    { (yyval.t) = 'P'; }
    break;

  case 199:
#line 1712 "compilers/imcc/imcc.y"
    {
           /* there'd normally be a str_dup() here, but the lexer already
            * copied the string, so it's safe to use directly */
           if ((IMCC_INFO(interp)->cur_pmc_type = pmc_type(interp,
               string_from_cstring(interp, (yyvsp[(1) - (1)].s), 0))) <= 0) {
               IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                    "Unknown PMC type '%s'\n", (yyvsp[(1) - (1)].s));
           }
         }
    break;

  case 200:
#line 1725 "compilers/imcc/imcc.y"
    { (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "set", 2, (yyvsp[(1) - (3)].sr), (yyvsp[(3) - (3)].sr));  }
    break;

  case 201:
#line 1727 "compilers/imcc/imcc.y"
    { (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(3) - (4)].s), 2, (yyvsp[(1) - (4)].sr), (yyvsp[(4) - (4)].sr));  }
    break;

  case 202:
#line 1729 "compilers/imcc/imcc.y"
    { (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(4) - (5)].s), 3, (yyvsp[(1) - (5)].sr), (yyvsp[(3) - (5)].sr), (yyvsp[(5) - (5)].sr));  }
    break;

  case 203:
#line 1731 "compilers/imcc/imcc.y"
    { (yyval.i) = iINDEXFETCH(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(1) - (6)].sr), (yyvsp[(3) - (6)].sr), (yyvsp[(5) - (6)].sr)); }
    break;

  case 204:
#line 1733 "compilers/imcc/imcc.y"
    { (yyval.i) = iINDEXSET(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(1) - (6)].sr), (yyvsp[(3) - (6)].sr), (yyvsp[(6) - (6)].sr)); }
    break;

  case 205:
#line 1738 "compilers/imcc/imcc.y"
    { (yyval.i) = iNEW(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(1) - (7)].sr), (yyvsp[(4) - (7)].s), (yyvsp[(6) - (7)].sr), 1); }
    break;

  case 206:
#line 1741 "compilers/imcc/imcc.y"
    {
           add_pcc_result((yyvsp[(3) - (3)].i)->symregs[0], (yyvsp[(1) - (3)].sr));
           IMCC_INFO(interp)->cur_call = NULL;
           (yyval.i) = 0;
         }
    break;

  case 207:
#line 1747 "compilers/imcc/imcc.y"
    {
           (yyval.i) = IMCC_create_itcall_label(interp);
         }
    break;

  case 208:
#line 1751 "compilers/imcc/imcc.y"
    {
           IMCC_itcall_sub(interp, (yyvsp[(6) - (9)].sr));
           IMCC_INFO(interp)->cur_call = NULL;
         }
    break;

  case 212:
#line 1759 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "null", 1, (yyvsp[(1) - (3)].sr));
         }
    break;

  case 213:
#line 1766 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"not"; }
    break;

  case 214:
#line 1767 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"bnot"; }
    break;

  case 215:
#line 1768 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"neg"; }
    break;

  case 216:
#line 1772 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"sub"; }
    break;

  case 217:
#line 1773 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"add"; }
    break;

  case 218:
#line 1774 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"mul"; }
    break;

  case 219:
#line 1775 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"div"; }
    break;

  case 220:
#line 1776 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"mod"; }
    break;

  case 221:
#line 1777 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"fdiv"; }
    break;

  case 222:
#line 1778 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"pow"; }
    break;

  case 223:
#line 1779 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"concat"; }
    break;

  case 224:
#line 1780 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"iseq"; }
    break;

  case 225:
#line 1781 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"isne"; }
    break;

  case 226:
#line 1782 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"isgt"; }
    break;

  case 227:
#line 1783 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"isge"; }
    break;

  case 228:
#line 1784 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"islt"; }
    break;

  case 229:
#line 1785 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"isle"; }
    break;

  case 230:
#line 1786 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"shl"; }
    break;

  case 231:
#line 1787 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"shr"; }
    break;

  case 232:
#line 1788 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"lsr"; }
    break;

  case 233:
#line 1789 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"and"; }
    break;

  case 234:
#line 1790 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"or"; }
    break;

  case 235:
#line 1791 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"xor"; }
    break;

  case 236:
#line 1792 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"band"; }
    break;

  case 237:
#line 1793 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"bor"; }
    break;

  case 238:
#line 1794 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"bxor"; }
    break;

  case 239:
#line 1800 "compilers/imcc/imcc.y"
    {
           (yyval.i) = IMCC_create_itcall_label(interp);
           (yyval.i)->type &= ~ITCALL;
           (yyval.i)->type |= ITRESULT;
         }
    break;

  case 240:
#line 1805 "compilers/imcc/imcc.y"
    {  (yyval.i) = 0; }
    break;

  case 241:
#line 1812 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(2) - (3)].s), 2, (yyvsp[(1) - (3)].sr), (yyvsp[(3) - (3)].sr));
         }
    break;

  case 242:
#line 1818 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"add"; }
    break;

  case 243:
#line 1819 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"sub"; }
    break;

  case 244:
#line 1820 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"mul"; }
    break;

  case 245:
#line 1821 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"div"; }
    break;

  case 246:
#line 1822 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"mod"; }
    break;

  case 247:
#line 1823 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"fdiv"; }
    break;

  case 248:
#line 1824 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"concat"; }
    break;

  case 249:
#line 1825 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"band"; }
    break;

  case 250:
#line 1826 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"bor"; }
    break;

  case 251:
#line 1827 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"bxor"; }
    break;

  case 252:
#line 1828 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"shr"; }
    break;

  case 253:
#line 1829 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"shl"; }
    break;

  case 254:
#line 1830 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"lsr"; }
    break;

  case 255:
#line 1836 "compilers/imcc/imcc.y"
    {
        (yyval.i) = func_ins(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(1) - (4)].sr), (yyvsp[(3) - (4)].s),
                      IMCC_INFO(interp) -> regs,
                      IMCC_INFO(interp) -> nargs,
                      IMCC_INFO(interp) -> keyvec, 1);
         mem_sys_free((yyvsp[(3) - (4)].s));
       }
    break;

  case 256:
#line 1846 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address(interp, (yyvsp[(1) - (1)].s));  mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 257:
#line 1847 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address_fromc(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 258:
#line 1848 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address_u(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 259:
#line 1850 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = (yyvsp[(1) - (1)].sr);
           if ((yyvsp[(1) - (1)].sr)->set != 'P')
               IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR, "Sub isn't a PMC");
         }
    break;

  case 260:
#line 1856 "compilers/imcc/imcc.y"
    {
            /* disallow bareword method names; SREG name constants are fine */
            char *name = (yyvsp[(3) - (3)].sr)->name;
            if (!((yyvsp[(3) - (3)].sr)->type & VTREG)) {
                if (*name != '\'' || *name != '\"')
                    IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
                        "Bareword method name '%s' not allowed in PIR",
                        (yyvsp[(3) - (3)].sr)->name);
            }

            IMCC_INFO(interp)->cur_obj = (yyvsp[(1) - (3)].sr);
            (yyval.sr)                         = (yyvsp[(3) - (3)].sr);
        }
    break;

  case 261:
#line 1870 "compilers/imcc/imcc.y"
    {
            IMCC_INFO(interp)->cur_obj = (yyvsp[(1) - (3)].sr);
            (yyval.sr)                         = mk_const(interp, (yyvsp[(3) - (3)].s), 'S');
            mem_sys_free((yyvsp[(3) - (3)].s));
         }
    break;

  case 262:
#line 1875 "compilers/imcc/imcc.y"
    { IMCC_INFO(interp)->cur_obj = (yyvsp[(1) - (3)].sr); (yyval.sr) = (yyvsp[(3) - (3)].sr); }
    break;

  case 263:
#line 1881 "compilers/imcc/imcc.y"
    {
           (yyval.i) = IMCC_create_itcall_label(interp);
           IMCC_itcall_sub(interp, (yyvsp[(1) - (1)].sr));
         }
    break;

  case 264:
#line 1885 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(2) - (5)].i); }
    break;

  case 265:
#line 1889 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 266:
#line 1891 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_arg(interp, IMCC_INFO(interp)->cur_call, IMCC_INFO(interp)->adv_named_id, (yyvsp[(3) - (3)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_arg(IMCC_INFO(interp)->cur_call, (yyvsp[(3) - (3)].sr));
         }
    break;

  case 267:
#line 1901 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_arg(interp, IMCC_INFO(interp)->cur_call, IMCC_INFO(interp)->adv_named_id, (yyvsp[(1) - (1)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_arg(IMCC_INFO(interp)->cur_call, (yyvsp[(1) - (1)].sr));
         }
    break;

  case 268:
#line 1911 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           add_pcc_named_arg(interp, IMCC_INFO(interp)->cur_call, (yyvsp[(3) - (5)].s), (yyvsp[(5) - (5)].sr));
           mem_sys_free((yyvsp[(3) - (5)].s));
         }
    break;

  case 269:
#line 1917 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           add_pcc_named_arg(interp, IMCC_INFO(interp)->cur_call, (yyvsp[(1) - (3)].s), (yyvsp[(3) - (3)].sr));
           mem_sys_free((yyvsp[(1) - (3)].s));
         }
    break;

  case 270:
#line 1925 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(1) - (2)].sr); (yyval.sr)->type |= (yyvsp[(2) - (2)].t); }
    break;

  case 271:
#line 1929 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 272:
#line 1930 "compilers/imcc/imcc.y"
    { (yyval.t) = (yyvsp[(1) - (2)].t) | (yyvsp[(2) - (2)].t); }
    break;

  case 273:
#line 1934 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_FLAT; }
    break;

  case 274:
#line 1935 "compilers/imcc/imcc.y"
    { (yyval.t) = VT_NAMED; }
    break;

  case 275:
#line 1938 "compilers/imcc/imcc.y"
    { adv_named_set(interp, (yyvsp[(3) - (4)].s)); (yyval.t) = 0; }
    break;

  case 276:
#line 1942 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(1) - (2)].sr); (yyval.sr)->type |= (yyvsp[(2) - (2)].t); }
    break;

  case 277:
#line 1947 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_result(interp, IMCC_INFO(interp)->cur_call, IMCC_INFO(interp)->adv_named_id, (yyvsp[(3) - (3)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_result(IMCC_INFO(interp)->cur_call, (yyvsp[(3) - (3)].sr));
         }
    break;

  case 278:
#line 1957 "compilers/imcc/imcc.y"
    {
           add_pcc_named_result(interp, IMCC_INFO(interp)->cur_call, (yyvsp[(3) - (5)].s), (yyvsp[(5) - (5)].sr));
           mem_sys_free((yyvsp[(3) - (5)].s));
         }
    break;

  case 279:
#line 1962 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = 0;
           if (IMCC_INFO(interp)->adv_named_id) {
               add_pcc_named_result(interp, IMCC_INFO(interp)->cur_call, IMCC_INFO(interp)->adv_named_id, (yyvsp[(1) - (1)].sr));
               IMCC_INFO(interp)->adv_named_id = NULL;
           }
           else
               add_pcc_result(IMCC_INFO(interp)->cur_call, (yyvsp[(1) - (1)].sr));
         }
    break;

  case 280:
#line 1972 "compilers/imcc/imcc.y"
    {
           add_pcc_named_result(interp, IMCC_INFO(interp)->cur_call, (yyvsp[(1) - (3)].s), (yyvsp[(3) - (3)].sr));
           mem_sys_free((yyvsp[(1) - (3)].s));
         }
    break;

  case 281:
#line 1976 "compilers/imcc/imcc.y"
    { (yyval.sr) = 0; }
    break;

  case 282:
#line 1980 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 283:
#line 1981 "compilers/imcc/imcc.y"
    { (yyval.i) = (yyvsp[(1) - (1)].i); }
    break;

  case 284:
#line 1986 "compilers/imcc/imcc.y"
    {
           (yyval.i) =MK_I(interp, IMCC_INFO(interp)->cur_unit, inv_op((yyvsp[(3) - (6)].s)), 3, (yyvsp[(2) - (6)].sr), (yyvsp[(4) - (6)].sr), (yyvsp[(6) - (6)].sr));
         }
    break;

  case 285:
#line 1990 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "unless_null", 2, (yyvsp[(3) - (5)].sr), (yyvsp[(5) - (5)].sr));
         }
    break;

  case 286:
#line 1994 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "unless", 2, (yyvsp[(2) - (4)].sr), (yyvsp[(4) - (4)].sr));
         }
    break;

  case 287:
#line 2001 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "if", 2, (yyvsp[(2) - (4)].sr), (yyvsp[(4) - (4)].sr));
         }
    break;

  case 288:
#line 2005 "compilers/imcc/imcc.y"
    {
           (yyval.i) =MK_I(interp, IMCC_INFO(interp)->cur_unit, (yyvsp[(3) - (6)].s), 3, (yyvsp[(2) - (6)].sr), (yyvsp[(4) - (6)].sr), (yyvsp[(6) - (6)].sr));
         }
    break;

  case 289:
#line 2009 "compilers/imcc/imcc.y"
    {
           (yyval.i) = MK_I(interp, IMCC_INFO(interp)->cur_unit, "if_null", 2, (yyvsp[(3) - (5)].sr), (yyvsp[(5) - (5)].sr));
         }
    break;

  case 290:
#line 2015 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 291:
#line 2016 "compilers/imcc/imcc.y"
    { (yyval.t) = 0; }
    break;

  case 292:
#line 2020 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"eq"; }
    break;

  case 293:
#line 2021 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"ne"; }
    break;

  case 294:
#line 2022 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"gt"; }
    break;

  case 295:
#line 2023 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"ge"; }
    break;

  case 296:
#line 2024 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"lt"; }
    break;

  case 297:
#line 2025 "compilers/imcc/imcc.y"
    { (yyval.s) = (char *)"le"; }
    break;

  case 300:
#line 2034 "compilers/imcc/imcc.y"
    { (yyval.sr) = NULL; }
    break;

  case 301:
#line 2035 "compilers/imcc/imcc.y"
    { (yyval.sr) = (yyvsp[(1) - (1)].sr); }
    break;

  case 302:
#line 2039 "compilers/imcc/imcc.y"
    { (yyval.sr) = IMCC_INFO(interp)->regs[0]; }
    break;

  case 304:
#line 2044 "compilers/imcc/imcc.y"
    { IMCC_INFO(interp)->regs[IMCC_INFO(interp)->nargs++] = (yyvsp[(1) - (1)].sr); }
    break;

  case 305:
#line 2046 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp) -> regs[IMCC_INFO(interp)->nargs++] = (yyvsp[(1) - (4)].sr);
           IMCC_INFO(interp) -> keyvec |= KEY_BIT(IMCC_INFO(interp)->nargs);
           IMCC_INFO(interp) -> regs[IMCC_INFO(interp)->nargs++] = (yyvsp[(3) - (4)].sr);
           (yyval.sr) = (yyvsp[(1) - (4)].sr);
         }
    break;

  case 306:
#line 2053 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp) -> regs[IMCC_INFO(interp)->nargs++] = (yyvsp[(2) - (3)].sr);
           (yyval.sr) = (yyvsp[(2) - (3)].sr);
         }
    break;

  case 308:
#line 2060 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address_fromc(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 309:
#line 2061 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address_u(interp, (yyvsp[(1) - (1)].s));  mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 310:
#line 2065 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 311:
#line 2066 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_sub_address(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 312:
#line 2070 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_label_address(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 313:
#line 2071 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_label_address(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 318:
#line 2085 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->nkeys    = 0;
           IMCC_INFO(interp)->in_slice = 0;
         }
    break;

  case 319:
#line 2090 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = link_keys(interp,
                          IMCC_INFO(interp)->nkeys,
                          IMCC_INFO(interp)->keys, 0);
         }
    break;

  case 320:
#line 2098 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->nkeys = 0;
           IMCC_INFO(interp)->in_slice = 0;
         }
    break;

  case 321:
#line 2103 "compilers/imcc/imcc.y"
    {
           (yyval.sr) = link_keys(interp,
                          IMCC_INFO(interp)->nkeys,
                          IMCC_INFO(interp)->keys, 1);
         }
    break;

  case 322:
#line 2111 "compilers/imcc/imcc.y"
    { IMCC_INFO(interp)->keys[IMCC_INFO(interp)->nkeys++] = (yyvsp[(1) - (1)].sr); }
    break;

  case 323:
#line 2113 "compilers/imcc/imcc.y"
    {
           IMCC_INFO(interp)->keys[IMCC_INFO(interp)->nkeys++] = (yyvsp[(3) - (3)].sr);
           (yyval.sr) = IMCC_INFO(interp)->keys[0];
         }
    break;

  case 324:
#line 2121 "compilers/imcc/imcc.y"
    {
           if (IMCC_INFO(interp)->in_slice)
               (yyvsp[(1) - (1)].sr)->type |= VT_START_SLICE | VT_END_SLICE;
           (yyval.sr) = (yyvsp[(1) - (1)].sr);
         }
    break;

  case 325:
#line 2129 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_symreg(interp, (yyvsp[(1) - (1)].s), 'I'); }
    break;

  case 326:
#line 2130 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_symreg(interp, (yyvsp[(1) - (1)].s), 'N'); }
    break;

  case 327:
#line 2131 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_symreg(interp, (yyvsp[(1) - (1)].s), 'S'); }
    break;

  case 328:
#line 2132 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_symreg(interp, (yyvsp[(1) - (1)].s), 'P'); }
    break;

  case 329:
#line 2133 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_pasm_reg(interp, (yyvsp[(1) - (1)].s)); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 330:
#line 2137 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, (yyvsp[(1) - (1)].s), 'I'); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 331:
#line 2138 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, (yyvsp[(1) - (1)].s), 'N'); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 332:
#line 2139 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, (yyvsp[(1) - (1)].s), 'S'); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;

  case 333:
#line 2140 "compilers/imcc/imcc.y"
    { (yyval.sr) = mk_const(interp, (yyvsp[(1) - (1)].s), 'U'); mem_sys_free((yyvsp[(1) - (1)].s)); }
    break;


/* Line 1267 of yacc.c.  */
#line 4877 "compilers/imcc/imcparser.c"
      default: break;
    }
  YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);

  YYPOPSTACK (yylen);
  yylen = 0;
  YY_STACK_PRINT (yyss, yyssp);

  *++yyvsp = yyval;


  /* Now `shift' the result of the reduction.  Determine what state
     that goes to, based on the state we popped back to and the rule
     number reduced by.  */

  yyn = yyr1[yyn];

  yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
  if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
    yystate = yytable[yystate];
  else
    yystate = yydefgoto[yyn - YYNTOKENS];

  goto yynewstate;


/*------------------------------------.
| yyerrlab -- here on detecting error |
`------------------------------------*/
yyerrlab:
  /* If not already recovering from an error, report this error.  */
  if (!yyerrstatus)
    {
      ++yynerrs;
#if ! YYERROR_VERBOSE
      yyerror (yyscanner, interp, YY_("syntax error"));
#else
      {
	YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
	if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
	  {
	    YYSIZE_T yyalloc = 2 * yysize;
	    if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
	      yyalloc = YYSTACK_ALLOC_MAXIMUM;
	    if (yymsg != yymsgbuf)
	      YYSTACK_FREE (yymsg);
	    yymsg = (char *) YYSTACK_ALLOC (yyalloc);
	    if (yymsg)
	      yymsg_alloc = yyalloc;
	    else
	      {
		yymsg = yymsgbuf;
		yymsg_alloc = sizeof yymsgbuf;
	      }
	  }

	if (0 < yysize && yysize <= yymsg_alloc)
	  {
	    (void) yysyntax_error (yymsg, yystate, yychar);
	    yyerror (yyscanner, interp, yymsg);
	  }
	else
	  {
	    yyerror (yyscanner, interp, YY_("syntax error"));
	    if (yysize != 0)
	      goto yyexhaustedlab;
	  }
      }
#endif
    }



  if (yyerrstatus == 3)
    {
      /* If just tried and failed to reuse look-ahead token after an
	 error, discard it.  */

      if (yychar <= YYEOF)
	{
	  /* Return failure if at end of input.  */
	  if (yychar == YYEOF)
	    YYABORT;
	}
      else
	{
	  yydestruct ("Error: discarding",
		      yytoken, &yylval, yyscanner, interp);
	  yychar = YYEMPTY;
	}
    }

  /* Else will try to reuse look-ahead token after shifting the error
     token.  */
  goto yyerrlab1;


/*---------------------------------------------------.
| yyerrorlab -- error raised explicitly by YYERROR.  |
`---------------------------------------------------*/
yyerrorlab:

  /* Pacify compilers like GCC when the user code never invokes
     YYERROR and the label yyerrorlab therefore never appears in user
     code.  */
  if (/*CONSTCOND*/ 0)
     goto yyerrorlab;

  /* Do not reclaim the symbols of the rule which action triggered
     this YYERROR.  */
  YYPOPSTACK (yylen);
  yylen = 0;
  YY_STACK_PRINT (yyss, yyssp);
  yystate = *yyssp;
  goto yyerrlab1;


/*-------------------------------------------------------------.
| yyerrlab1 -- common code for both syntax error and YYERROR.  |
`-------------------------------------------------------------*/
yyerrlab1:
  yyerrstatus = 3;	/* Each real token shifted decrements this.  */

  for (;;)
    {
      yyn = yypact[yystate];
      if (yyn != YYPACT_NINF)
	{
	  yyn += YYTERROR;
	  if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
	    {
	      yyn = yytable[yyn];
	      if (0 < yyn)
		break;
	    }
	}

      /* Pop the current state because it cannot handle the error token.  */
      if (yyssp == yyss)
	YYABORT;


      yydestruct ("Error: popping",
		  yystos[yystate], yyvsp, yyscanner, interp);
      YYPOPSTACK (1);
      yystate = *yyssp;
      YY_STACK_PRINT (yyss, yyssp);
    }

  if (yyn == YYFINAL)
    YYACCEPT;

  *++yyvsp = yylval;


  /* Shift the error token.  */
  YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);

  yystate = yyn;
  goto yynewstate;


/*-------------------------------------.
| yyacceptlab -- YYACCEPT comes here.  |
`-------------------------------------*/
yyacceptlab:
  yyresult = 0;
  goto yyreturn;

/*-----------------------------------.
| yyabortlab -- YYABORT comes here.  |
`-----------------------------------*/
yyabortlab:
  yyresult = 1;
  goto yyreturn;

#ifndef yyoverflow
/*-------------------------------------------------.
| yyexhaustedlab -- memory exhaustion comes here.  |
`-------------------------------------------------*/
yyexhaustedlab:
  yyerror (yyscanner, interp, YY_("memory exhausted"));
  yyresult = 2;
  /* Fall through.  */
#endif

yyreturn:
  if (yychar != YYEOF && yychar != YYEMPTY)
     yydestruct ("Cleanup: discarding lookahead",
		 yytoken, &yylval, yyscanner, interp);
  /* Do not reclaim the symbols of the rule which action triggered
     this YYABORT or YYACCEPT.  */
  YYPOPSTACK (yylen);
  YY_STACK_PRINT (yyss, yyssp);
  while (yyssp != yyss)
    {
      yydestruct ("Cleanup: popping",
		  yystos[*yyssp], yyvsp, yyscanner, interp);
      YYPOPSTACK (1);
    }
#ifndef yyoverflow
  if (yyss != yyssa)
    YYSTACK_FREE (yyss);
#endif
#if YYERROR_VERBOSE
  if (yymsg != yymsgbuf)
    YYSTACK_FREE (yymsg);
#endif
  /* Make sure YYID is used.  */
  return YYID (yyresult);
}


#line 2146 "compilers/imcc/imcc.y"


/* I need this prototype somewhere... */
char *yyget_text(yyscan_t yyscanner);

/* I do not like this function, but, atm, it is the only way I can
 * make the code in yyerror work without segfault on some specific
 * cases.
 */
/* int yyholds_char(yyscan_t yyscanner); */

int yyerror(void *yyscanner, PARROT_INTERP, const char *s)
{
    /* If the error occurr in the end of the buffer (I mean, the last
     * token was already read), yyget_text will return a pointer
     * outside the bison buffer, and thus, not "accessible" by
     * us. This means it may segfault. */
    const char * const chr = yyget_text((yyscan_t)yyscanner);

    /* IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR, s); */
    /* --- This was called before, not sure if I should call some
           similar function that does not die like this one. */

    /* Basically, if current token is a newline, it mean the error was
     * before the newline, and thus, line is the line *after* the
     * error. Instead of duplicating code for both cases (the 'newline' and
     * non-newline case, do the test twice; efficiency is not important when
     * we have an error anyway.
     */
    if (!at_eof(yyscanner)) {
        if (*chr == '\n') {
            IMCC_INFO(interp)->line--;
        }

        IMCC_warning(interp, "error:imcc:%s", s);
        /* don't print the current token if it is a newline */
        if (*chr != '\n') {
            IMCC_warning(interp, " ('%s')", chr);
        }
        IMCC_print_inc(interp);

        if (*chr == '\n') {
            IMCC_INFO(interp)->line++;
        }

    }
    else { /* scanner is at end of file; just to be sure, do not print "current" token. */
        IMCC_warning(interp, "error:imcc:%s", s);
        IMCC_print_inc(interp);
    }

    return 0;
}

/*
 * Local variables:
 *   c-file-style: "parrot"
 * End:
 * vim: expandtab shiftwidth=4:
 */

