Anarres-Mud-Driver

 view release on metacpan or  search on metacpan

Compiler/lexer.c  view on Meta::CPAN


		if ( ! amd_yy_start_stack )
			amd_yy_start_stack = (int *) amd_yy_flex_alloc( new_size );

		else
			amd_yy_start_stack = (int *) amd_yy_flex_realloc(
					(void *) amd_yy_start_stack, new_size );

		if ( ! amd_yy_start_stack )
			YY_FATAL_ERROR(
			"out of memory expanding start-condition stack" );
		}

	amd_yy_start_stack[amd_yy_start_stack_ptr++] = YY_START;

	BEGIN(new_state);
	}
#endif


#ifndef YY_NO_POP_STATE

Compiler/parser.c  view on Meta::CPAN

    break;}
case 174:
#line 1555 "parser.y"
{
			amd_yyval.av = amd_yyvsp[-1].av;
		;
    break;}
case 175:
#line 1562 "parser.y"
{
			/* This doesn't expand the pairs into a single list.
			 * There is a hack elsewhere. */
			amd_yyval.av = amd_yyvsp[-1].av;
		;
    break;}
case 176:
#line 1572 "parser.y"
{
			amd_yyval.obj = amd_yyvsp[-1].obj;
		;
    break;}

Compiler/parser.y  view on Meta::CPAN

%left '*' '%' '/'
%right '!' '~'
%nonassoc L_INC L_DEC

/* These aren't strictly necessary, but they help debugging. */

%token '{' '}' ',' ';' ':' '(' ')' '[' ']' '=' '$'

	/* I should have a new type 'node' in here for blessed objects
	 * which are specifically parse nodes. */
	/* It is very very tempting to expand this to say 12 bytes
	 * to save on the use of AVs for type declarators. */
%union {
	int			 number;
	const char	*str;
	SV			*sv;
	SV			*obj;
	AV			*av;
	struct _assoc_t {
		SV	*key;
		SV	*value;

Compiler/parser.y  view on Meta::CPAN

array
		: L_ARRAY_START opt_arg_list_comma L_ARRAY_END
		{
			$$ = $2;
		}
	;

mapping
		: L_MAP_START opt_assoc_arg_list_comma L_MAP_END
		{
			/* This doesn't expand the pairs into a single list.
			 * There is a hack elsewhere. */
			$$ = $2;
		}
	;

		/* Also things like (: foo :) ? */
closure
		: L_FUNCTION_START list_exp L_FUNCTION_END
		{
			$$ = $2;

lib/Driver/Compiler/Generate.pm  view on Meta::CPAN

							
							AddEq SubEq DivEq MulEq ModEq
							AndEq OrEq XorEq
							LshEq RshEq

							StmtForeach
							),
		);

# XXX For the purposes of things like Member, I need to be able to
# insert both expanded and nonexpanded versions of tokens.
# So I need to be able to insert "A", _A_ and @A@ tokens, for example.

sub gensub {
	my ($self, $name, $code) = @_;

	confess "No code template for opcode '$name'" unless defined $code;

	foreach ('A'..'F') {	# Say ...
		my $arg = ord($_) - ord('A');
		# XXX This 'quote' routine doesn't necessarily quote



( run in 1.403 second using v1.01-cache-2.11-cpan-97f6503c9c8 )