summaryrefslogtreecommitdiff
path: root/lib/as3
diff options
context:
space:
mode:
authorMatthias Kramm <kramm@quiss.org>2010-01-16 22:12:36 -0800
committerMatthias Kramm <kramm@quiss.org>2010-01-16 22:12:36 -0800
commit86683e9e9c61cb3f0164a1ffcf151ccefa8871df (patch)
tree7f689749ca667d3f7d37e1609f69c1464d7aceea /lib/as3
parent5c7bc47d1c32e31480960d7a1ab5419628b505ff (diff)
implemented .swc import
Diffstat (limited to 'lib/as3')
-rw-r--r--lib/as3/Makefile2
-rw-r--r--lib/as3/assets.c2
-rw-r--r--lib/as3/import.c170
-rw-r--r--lib/as3/parser.tab.c287
-rw-r--r--lib/as3/pool.c6
5 files changed, 314 insertions, 153 deletions
diff --git a/lib/as3/Makefile b/lib/as3/Makefile
index 826281cb..642daf14 100644
--- a/lib/as3/Makefile
+++ b/lib/as3/Makefile
@@ -27,7 +27,7 @@ mklib.o: mklib.c parser.tab.h parser.h
$(C) mklib.c -o mklib.o
parser: main.o tokenizer.yy.c ../librfxswf.a ../libbase.a parser.tab.h
- $(L) main.o ../librfxswf.a ../libbase.a -o parser -lz
+ $(L) main.o ../librfxswf.a ../libbase.a -o parser -lz -lzzip
rfxswf_modules=../drawer.o ../rfxswf.o ../modules/*.o ../lame/*.o ../action/*.o ../MD5.o $(MODULES)
mklib: mklib.o $(rfxswf_modules) import.o registry.o tokenizer.yy.o parser.tab.o files.o compiler.o assets.o ../libbase.a
diff --git a/lib/as3/assets.c b/lib/as3/assets.c
index 8fbab470..f6b4aee8 100644
--- a/lib/as3/assets.c
+++ b/lib/as3/assets.c
@@ -27,7 +27,7 @@ asset_resolver_t* swf_ParseAssets(SWF*swf)
{
NEW(asset_resolver_t,assets);
assets->name2asset = dict_new2(&charptr_type);
- assets->id2asset = malloc(sizeof(abc_asset_t*)*65536);
+ assets->id2asset = rfx_calloc(sizeof(abc_asset_t*)*65536);
TAG*tag = swf->firstTag;
while(tag) {
diff --git a/lib/as3/import.c b/lib/as3/import.c
index 59dbac0e..df0271e1 100644
--- a/lib/as3/import.c
+++ b/lib/as3/import.c
@@ -26,6 +26,10 @@
#include "tokenizer.h"
#include "assets.h"
#include "../os.h"
+#include "../xml.h"
+#ifdef HAVE_ZZIP
+#include "zzip/lib.h"
+#endif
static void import_code(void*_abc, char*filename, int pass, asset_bundle_t*a);
@@ -43,10 +47,15 @@ void as3_import_abc(char*filename)
free(tag);
}
-void as3_import_swf(char*filename)
+typedef struct _deps {
+ const char*name;
+ struct _deps*next;
+} deps_t;
+
+void as3_import_swf2(reader_t*r, char*filename, dict_t*deps)
{
- SWF* swf = swf_OpenSWF(filename);
- if(!swf)
+ SWF _swf,*swf=&_swf;
+ if(swf_ReadSWF2(r, &_swf)<0)
return;
swf_FoldAll(swf);
@@ -54,34 +63,177 @@ void as3_import_swf(char*filename)
asset_resolver_t* assets = swf_ParseAssets(swf);
+ asset_bundle_list_t* asset_bundles = list_new();
+
+ dict_t*name2bundle = dict_new();
/* pass 1 */
while(tag) {
if(tag->id == ST_DOABC || tag->id == ST_RAWABC) {
abc_file_t*abc = swf_ReadABC(tag);
import_code(abc, filename, 0, 0);
- swf_FreeABC(abc);
+ NEW(asset_bundle_t, a);
+ a->file = abc;
+ if(abc->name) {
+ dict_put(name2bundle, abc->name, a);
+ }
+ list_append(asset_bundles, a);
}
tag = tag->next;
}
tag = swf->firstTag;
+ asset_bundle_list_t*b = asset_bundles;
/* pass 2 */
while(tag) {
if(tag->id == ST_DOABC || tag->id == ST_RAWABC) {
- abc_file_t*abc = swf_ReadABC(tag); //FIXME: mem leak
+ asset_bundle_t*a = b->asset_bundle;
+ abc_file_t*abc = a->file;
swf_ResolveAssets(assets, abc);
- NEW(asset_bundle_t, a);
- a->file = abc;
+ if(deps && abc->name) {
+ deps_t*d = dict_lookup(deps, abc->name);
+ while(d) {
+ if(d->name) {
+ asset_bundle_t*other = dict_lookup(name2bundle, d->name);
+ list_append(a->dependencies, other);
+ }
+ d = d->next;
+ }
+ }
registry_add_asset(a);
import_code(abc, filename, 1, a);
+ b=b->next;
}
tag = tag->next;
}
+ dict_destroy(name2bundle);
+ list_free(asset_bundles);
+
//swf_FreeTags(swf); // FIXME: mem leak
- free(swf);
+}
+
+void as3_import_swf(char*filename)
+{
+ reader_t reader;
+ reader_init_filereader2(&reader, filename);
+ as3_import_swf2(&reader, filename, 0);
+ reader.dealloc(&reader);
+}
+
+#ifdef HAVE_ZZIP
+typedef struct _catalog_state {
+ char*xml_filename;
+ char in_libraries;
+ char*library;
+ char*script;
+ dict_t*deps;
+ deps_t*current_deps;
+ dict_t*name2deps;
+ dict_t*id2script;
+ ZZIP_DIR*dir;
+} catalog_state_t;
+
+const char* fa(catalog_state_t*state, xmlattribute_t*attr, const char*name)
+{
+ while(attr) {
+ if(!strcmp(attr->name, name)) return attr->value;
+ attr = attr->next;
+ }
+ syntaxerror("error parsing %s: attribute %s missing", state->xml_filename, name);
+}
+void catalog_start_tag(xmlconsumer_t*c, char*name, xmlattribute_t*attr)
+{
+ catalog_state_t*state = (catalog_state_t*)c->internal;
+ if(!strcmp(name, "libraries")) {
+ state->in_libraries = 1;
+ } else if(!strcmp(name, "library")) {
+ state->library = strdup(fa(state, attr, "path"));
+ } else if(!strcmp(name, "script")) {
+ state->script = strdup(fa(state, attr, "name"));
+ } else if(!strcmp(name, "def")) {
+ dict_put(state->id2script, strdup(fa(state, attr, "id")), strdup(state->script));
+ } else if(!strcmp(name, "dep")) {
+ NEW(deps_t,d);
+ d->name = strdup(fa(state, attr, "id"));
+ d->next = state->current_deps;
+ state->current_deps = d;
+ }
+}
+void catalog_data(xmlconsumer_t*c, char*data, int len)
+{
+ catalog_state_t*state = (catalog_state_t*)c->internal;
+}
+void catalog_end_tag(xmlconsumer_t*c, char*name)
+{
+ catalog_state_t*state = (catalog_state_t*)c->internal;
+ if(!strcmp(name, "libraries")) {
+ state->in_libraries = 0;
+ } else if(!strcmp(name, "library")) {
+ ZZIP_FILE*file = zzip_file_open(state->dir, state->library, 0);
+
+ DICT_ITERATE_DATA(state->deps,deps_t*,deps) {
+ while(deps) {
+ char*script = dict_lookup(state->id2script, deps->name);
+ if(!script) {
+ //as3_warning("when importing %s: depencency %s referenced in catalog.xml, but not found.", state->xml_filename, deps->name);
+ }
+ deps->name = script;
+ deps = deps->next;
+ }
+ }
+
+ if(!file) {
+ as3_warning("when importing %s: %s referenced in catalog.xml, but not found.", state->xml_filename, state->library);
+ } else {
+ reader_t r;
+ reader_init_zzipreader(&r, file);
+ as3_import_swf2(&r, state->library, state->deps);
+ r.dealloc(&r);
+ zzip_file_close(file);
+ }
+ dict_destroy(state->deps);
+ state->deps = 0;
+ free(state->library);
+ state->library = 0;
+ } else if(!strcmp(name, "script")) {
+ dict_put(state->deps, state->script, state->current_deps);
+ free(state->script);
+ state->current_deps = 0;
+ state->script = 0;
+ }
+}
+void as3_import_zipfile(char*filename)
+{
+ ZZIP_DIR*dir = zzip_opendir(filename);
+ if(!dir) as3_error("Error reading %s\n", filename);
+ ZZIP_FILE*file = zzip_file_open(dir, "catalog.xml", 0);
+ reader_t r;
+ reader_init_zzipreader(&r, file);
+
+ xmlconsumer_t c;
+ catalog_state_t state;
+ memset(&state, 0, sizeof(state));
+ state.dir = dir;
+ state.xml_filename = filename;
+ state.name2deps = dict_new();
+ state.id2script = dict_new();
+ state.deps = dict_new();
+ c.start_tag = catalog_start_tag;
+ c.data= catalog_data;
+ c.end_tag = catalog_end_tag;
+ c.internal = &state;
+
+ xml_parse(&r, &c);
+
+ r.dealloc(&r);
+}
+#else
+void as3_import_zipfile(char*filename)
+{
+ as3_warning("No zipfile support compiled in- can't import %s\n", filename);
}
+#endif
void as3_import_file(char*filename)
{
@@ -93,6 +245,8 @@ void as3_import_file(char*filename)
if(!strncmp(head, "FWS", 3) ||
!strncmp(head, "CWS", 3)) {
as3_import_swf(filename);
+ } else if(!strncmp(head, "PK", 2)) {
+ as3_import_zipfile(filename);
} else {
as3_import_abc(filename);
}
diff --git a/lib/as3/parser.tab.c b/lib/as3/parser.tab.c
index cbba2649..964770c4 100644
--- a/lib/as3/parser.tab.c
+++ b/lib/as3/parser.tab.c
@@ -2125,7 +2125,7 @@ code_t* insert_finally(code_t*c, code_t*finally, int tempvar)
/* Line 274 of skeleton.m4 */
-#line 3539 "parser.y"
+#line 3541 "parser.y"
node_t* resolve_identifier(const char*name);
node_t* get_descendants(node_t*e,const char*ns,const char*subnode,char multi, char attr)
@@ -2165,7 +2165,7 @@ code_t* insert_finally(code_t*c, code_t*finally, int tempvar)
/* Line 274 of skeleton.m4 */
-#line 3710 "parser.y"
+#line 3712 "parser.y"
node_t* var_read(variable_t*v)
{
@@ -2261,6 +2261,7 @@ code_t* insert_finally(code_t*c, code_t*finally, int tempvar)
/* look at actual classes, in the current package and imported */
if(!state->xmlfilter && (a = find_class(name))) {
+ registry_use(a);
if(state->cls && state->cls->info == (classinfo_t*)a && i_am_static) {
o.c = abc_getlocal_0(0);
o.t = TYPE_CLASS((classinfo_t*)a);
@@ -2298,7 +2299,7 @@ code_t* insert_finally(code_t*c, code_t*finally, int tempvar)
/* Line 274 of skeleton.m4 */
-#line 3866 "parser.y"
+#line 3869 "parser.y"
void add_active_url(const char*url)
{
@@ -2310,7 +2311,7 @@ code_t* insert_finally(code_t*c, code_t*finally, int tempvar)
/* Line 274 of skeleton.m4 */
-#line 2314 "parser.tab.c"
+#line 2315 "parser.tab.c"
#ifdef short
# undef short
@@ -2768,20 +2769,20 @@ static const yytype_uint16 yyrline[] =
2896, 2899, 2900, 2903, 2908, 2911, 2914, 2917, 2920, 2924,
2927, 2931, 2935, 2940, 2946, 2949, 2952, 2955, 2960, 2963,
2966, 2976, 2980, 2986, 2992, 3000, 3005, 3011, 3019, 3027,
- 3028, 3029, 3032, 3031, 3048, 3049, 3051, 3050, 3074, 3093,
- 3107, 3108, 3110, 3111, 3113, 3114, 3115, 3124, 3125, 3129,
- 3130, 3132, 3133, 3134, 3136, 3140, 3141, 3146, 3147, 3194,
- 3244, 3265, 3287, 3290, 3297, 3300, 3303, 3306, 3309, 3312,
- 3317, 3318, 3320, 3321, 3322, 3323, 3324, 3326, 3332, 3341,
- 3342, 3343, 3344, 3345, 3346, 3348, 3352, 3357, 3375, 3386,
- 3396, 3405, 3406, 3407, 3408, 3409, 3410, 3411, 3412, 3413,
- 3414, 3415, 3416, 3417, 3418, 3419, 3420, 3421, 3422, 3423,
- 3424, 3425, 3426, 3427, 3428, 3429, 3430, 3431, 3432, 3433,
- 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, 3442, 3443,
- 3444, 3445, 3446, 3447, 3448, 3449, 3450, 3452, 3453, 3454,
- 3455, 3457, 3472, 3480, 3480, 3534, 3535, 3536, 3537, 3577,
- 3580, 3587, 3590, 3601, 3609, 3613, 3620, 3624, 3634, 3645,
- 3841, 3875, 3882, 3889, 3896, 3918, 3925
+ 3028, 3029, 3032, 3031, 3048, 3049, 3051, 3050, 3074, 3094,
+ 3109, 3110, 3112, 3113, 3115, 3116, 3117, 3126, 3127, 3131,
+ 3132, 3134, 3135, 3136, 3138, 3142, 3143, 3148, 3149, 3196,
+ 3246, 3267, 3289, 3292, 3299, 3302, 3305, 3308, 3311, 3314,
+ 3319, 3320, 3322, 3323, 3324, 3325, 3326, 3328, 3334, 3343,
+ 3344, 3345, 3346, 3347, 3348, 3350, 3354, 3359, 3377, 3388,
+ 3398, 3407, 3408, 3409, 3410, 3411, 3412, 3413, 3414, 3415,
+ 3416, 3417, 3418, 3419, 3420, 3421, 3422, 3423, 3424, 3425,
+ 3426, 3427, 3428, 3429, 3430, 3431, 3432, 3433, 3434, 3435,
+ 3436, 3437, 3438, 3439, 3440, 3441, 3442, 3443, 3444, 3445,
+ 3446, 3447, 3448, 3449, 3450, 3451, 3452, 3454, 3455, 3456,
+ 3457, 3459, 3474, 3482, 3482, 3536, 3537, 3538, 3539, 3579,
+ 3582, 3589, 3592, 3603, 3611, 3615, 3622, 3626, 3636, 3647,
+ 3844, 3878, 3885, 3892, 3899, 3921, 3928
};
#endif
@@ -5911,7 +5912,7 @@ PASS2
{
PASS12
slotinfo_t*s = registry_find((yyvsp[(2) - (2)].classinfo)->package, (yyvsp[(2) - (2)].classinfo)->name);
- if(!s && as3_pass==1) {// || !(s->flags&FLAG_BUILTIN)) {
+ if(!s && as3_pass==1) {
as3_schedule_class((yyvsp[(2) - (2)].classinfo)->package, (yyvsp[(2) - (2)].classinfo)->name);
}
/*if(s && s->kind == INFOTYPE_VAR && TYPE_IS_NAMESPACE(s->type)) {
@@ -7171,6 +7172,7 @@ PASS12
slotinfo_t*s = find_class((yyvsp[(1) - (1)].id));
if(!s) syntaxerror("Could not find class/method %s (current package: %s)\n", (yyvsp[(1) - (1)].id), state->package);
(yyval.classinfo) = (classinfo_t*)s;
+ registry_use(s);
}
}
break;
@@ -7181,7 +7183,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3093 "parser.y"
+#line 3094 "parser.y"
{
PASS1 NEW(unresolvedinfo_t,c);
memset(c, 0, sizeof(*c));
@@ -7194,6 +7196,7 @@ PASS12
if(!s) syntaxerror("Couldn't find class/method %s.%s\n", (yyvsp[(1) - (3)].id), (yyvsp[(3) - (3)].id));
free((yyvsp[(1) - (3)].id));(yyvsp[(1) - (3)].id)=0;
(yyval.classinfo) = (classinfo_t*)s;
+ registry_use(s);
}
}
break;
@@ -7204,7 +7207,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3110 "parser.y"
+#line 3112 "parser.y"
{PASS12 (yyval.classinfo_list)=list_new();list_append((yyval.classinfo_list), (yyvsp[(1) - (1)].classinfo));}
}
break;
@@ -7215,7 +7218,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3111 "parser.y"
+#line 3113 "parser.y"
{PASS12 (yyval.classinfo_list)=(yyvsp[(1) - (3)].classinfo_list);list_append((yyval.classinfo_list),(yyvsp[(3) - (3)].classinfo));}
}
break;
@@ -7226,7 +7229,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3113 "parser.y"
+#line 3115 "parser.y"
{PASS12 (yyval.classinfo)=(yyvsp[(1) - (1)].classinfo);}
}
break;
@@ -7237,7 +7240,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3114 "parser.y"
+#line 3116 "parser.y"
{PASS12 (yyval.classinfo)=TYPE_ANY;}
}
break;
@@ -7248,7 +7251,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3115 "parser.y"
+#line 3117 "parser.y"
{PASS12 (yyval.classinfo)=TYPE_VOID;}
}
break;
@@ -7259,7 +7262,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3124 "parser.y"
+#line 3126 "parser.y"
{PASS12 (yyval.classinfo)=(yyvsp[(2) - (2)].classinfo);}
}
break;
@@ -7270,7 +7273,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3125 "parser.y"
+#line 3127 "parser.y"
{PASS12 (yyval.classinfo)=0;}
}
break;
@@ -7281,7 +7284,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3129 "parser.y"
+#line 3131 "parser.y"
{(yyval.value_list).cc=0;(yyval.value_list).number=0;}
}
break;
@@ -7292,7 +7295,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3130 "parser.y"
+#line 3132 "parser.y"
{(yyval.value_list)=(yyvsp[(2) - (3)].value_list);}
}
break;
@@ -7303,7 +7306,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3132 "parser.y"
+#line 3134 "parser.y"
{(yyval.value_list).cc=0;(yyval.value_list).number=0;}
}
break;
@@ -7314,7 +7317,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3136 "parser.y"
+#line 3138 "parser.y"
{(yyval.value_list).number=1;
(yyval.value_list).cc = (yyvsp[(1) - (1)].value).c;
}
@@ -7327,7 +7330,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3140 "parser.y"
+#line 3142 "parser.y"
{(yyval.value_list) = (yyvsp[(1) - (2)].value_list);}
}
break;
@@ -7338,7 +7341,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3141 "parser.y"
+#line 3143 "parser.y"
{
(yyval.value_list).number= (yyvsp[(1) - (2)].value_list).number+1;
(yyval.value_list).cc = code_append((yyvsp[(1) - (2)].value_list).cc, (yyvsp[(2) - (2)].value).c);
@@ -7352,7 +7355,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3147 "parser.y"
+#line 3149 "parser.y"
{
typedcode_t v = node_read((yyvsp[(2) - (4)].node));
(yyval.value).c = v.c;
@@ -7404,7 +7407,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3194 "parser.y"
+#line 3196 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (4)].node));
@@ -7463,7 +7466,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3244 "parser.y"
+#line 3246 "parser.y"
{
if(!state->cls) syntaxerror("super() not allowed outside of a class");
if(!state->method) syntaxerror("super() not allowed outside of a function");
@@ -7493,7 +7496,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3265 "parser.y"
+#line 3267 "parser.y"
{
typedcode_t v = node_read((yyvsp[(2) - (2)].node));
(yyval.value).c = v.c;
@@ -7524,7 +7527,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3287 "parser.y"
+#line 3289 "parser.y"
{
(yyval.code) = abc_returnvoid(0);
}
@@ -7537,7 +7540,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3290 "parser.y"
+#line 3292 "parser.y"
{
(yyval.code) = (yyvsp[(2) - (2)].value).c;
(yyval.code) = abc_returnvalue((yyval.code));
@@ -7551,7 +7554,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3297 "parser.y"
+#line 3299 "parser.y"
{
(yyval.value) = node_read((yyvsp[(1) - (1)].node));
}
@@ -7564,7 +7567,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3300 "parser.y"
+#line 3302 "parser.y"
{
(yyval.value) = node_read((yyvsp[(1) - (1)].node));
}
@@ -7577,7 +7580,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3303 "parser.y"
+#line 3305 "parser.y"
{
(yyval.node) = mkmultinode(&node_comma, (yyvsp[(1) - (1)].node));
}
@@ -7590,7 +7593,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3306 "parser.y"
+#line 3308 "parser.y"
{
(yyval.node) = multinode_extend((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));
}
@@ -7603,7 +7606,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3309 "parser.y"
+#line 3311 "parser.y"
{
(yyval.code) = node_exec((yyvsp[(1) - (1)].node));
}
@@ -7616,7 +7619,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3312 "parser.y"
+#line 3314 "parser.y"
{
(yyval.code) = (yyvsp[(1) - (3)].code);
(yyval.code) = code_append((yyval.code), node_exec((yyvsp[(3) - (3)].node)));
@@ -7630,7 +7633,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3317 "parser.y"
+#line 3319 "parser.y"
{(yyval.value_list).cc=0;(yyval.value_list).number=0;}
}
break;
@@ -7641,7 +7644,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3318 "parser.y"
+#line 3320 "parser.y"
{(yyval.value_list)=(yyvsp[(1) - (1)].value_list);}
}
break;
@@ -7652,7 +7655,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3320 "parser.y"
+#line 3322 "parser.y"
{(yyval.code)=abc_pushstring(0,(yyvsp[(1) - (1)].id));}
}
break;
@@ -7663,7 +7666,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3321 "parser.y"
+#line 3323 "parser.y"
{(yyval.code)=abc_pushstring2(0,&(yyvsp[(1) - (1)].str));}
}
break;
@@ -7674,7 +7677,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3322 "parser.y"
+#line 3324 "parser.y"
{syntaxerror("dictionary keys must be strings");}
}
break;
@@ -7685,7 +7688,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3323 "parser.y"
+#line 3325 "parser.y"
{syntaxerror("dictionary keys must be strings");}
}
break;
@@ -7696,7 +7699,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3324 "parser.y"
+#line 3326 "parser.y"
{syntaxerror("dictionary keys must be strings");}
}
break;
@@ -7707,7 +7710,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3326 "parser.y"
+#line 3328 "parser.y"
{
(yyval.value_list).cc = 0;
(yyval.value_list).cc = code_append((yyval.value_list).cc, (yyvsp[(1) - (3)].code));
@@ -7723,7 +7726,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3332 "parser.y"
+#line 3334 "parser.y"
{
(yyval.value_list).cc = (yyvsp[(1) - (5)].value_list).cc;
(yyval.value_list).number = (yyvsp[(1) - (5)].value_list).number+2;
@@ -7739,7 +7742,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3341 "parser.y"
+#line 3343 "parser.y"
{(yyval.node) = mkcodenode((yyvsp[(1) - (1)].value));}
}
break;
@@ -7750,7 +7753,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3342 "parser.y"
+#line 3344 "parser.y"
{(yyval.node) = mkcodenode((yyvsp[(1) - (1)].value));}
}
break;
@@ -7761,7 +7764,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3343 "parser.y"
+#line 3345 "parser.y"
{(yyval.node) = mkcodenode((yyvsp[(1) - (1)].value));}
}
break;
@@ -7772,7 +7775,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3344 "parser.y"
+#line 3346 "parser.y"
{(yyval.node) = mkcodenode((yyvsp[(1) - (1)].value));}
}
break;
@@ -7783,7 +7786,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3345 "parser.y"
+#line 3347 "parser.y"
{(yyval.node) = mkcodenode((yyvsp[(1) - (1)].value));}
}
break;
@@ -7794,7 +7797,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3346 "parser.y"
+#line 3348 "parser.y"
{(yyval.node) = (yyvsp[(1) - (1)].node);}
}
break;
@@ -7805,7 +7808,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3348 "parser.y"
+#line 3350 "parser.y"
{
(yyval.node) = mkconstnode((yyvsp[(1) - (1)].constant));
}
@@ -7818,7 +7821,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3352 "parser.y"
+#line 3354 "parser.y"
{
(yyval.node) = (yyvsp[(1) - (1)].node);
}
@@ -7831,7 +7834,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3357 "parser.y"
+#line 3359 "parser.y"
{
typedcode_t v;
v.c = 0;
@@ -7858,7 +7861,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3375 "parser.y"
+#line 3377 "parser.y"
{
PASS1
state->method->need_arguments = 1;
@@ -7877,7 +7880,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3386 "parser.y"
+#line 3388 "parser.y"
{
typedcode_t v;
v.c = code_new();
@@ -7895,7 +7898,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3396 "parser.y"
+#line 3398 "parser.y"
{
typedcode_t v;
v.c = code_new();
@@ -7913,7 +7916,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3405 "parser.y"
+#line 3407 "parser.y"
{(yyval.node) = mknode2(&node_lt,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7924,7 +7927,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3406 "parser.y"
+#line 3408 "parser.y"
{(yyval.node) = mknode2(&node_gt,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7935,7 +7938,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3407 "parser.y"
+#line 3409 "parser.y"
{(yyval.node) = mknode2(&node_le,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7946,7 +7949,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3408 "parser.y"
+#line 3410 "parser.y"
{(yyval.node) = mknode2(&node_ge,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7957,7 +7960,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3409 "parser.y"
+#line 3411 "parser.y"
{(yyval.node) = mknode2(&node_eqeq,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7968,7 +7971,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3410 "parser.y"
+#line 3412 "parser.y"
{(yyval.node) = mknode2(&node_eqeqeq,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7979,7 +7982,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3411 "parser.y"
+#line 3413 "parser.y"
{(yyval.node) = mknode2(&node_noteqeq,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -7990,7 +7993,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3412 "parser.y"
+#line 3414 "parser.y"
{(yyval.node) = mknode2(&node_noteq,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -8001,7 +8004,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3413 "parser.y"
+#line 3415 "parser.y"
{(yyval.node) = mknode2(&node_oror,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -8012,7 +8015,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3414 "parser.y"
+#line 3416 "parser.y"
{(yyval.node) = mknode2(&node_andand,(yyvsp[(1) - (3)].node),(yyvsp[(3) - (3)].node));}
}
break;
@@ -8023,7 +8026,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3415 "parser.y"
+#line 3417 "parser.y"
{(yyval.node) = mknode1(&node_not, (yyvsp[(2) - (2)].node));}
}
break;
@@ -8034,7 +8037,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3416 "parser.y"
+#line 3418 "parser.y"
{(yyval.node) = mknode1(&node_bitnot, (yyvsp[(2) - (2)].node));}
}
break;
@@ -8045,7 +8048,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3417 "parser.y"
+#line 3419 "parser.y"
{(yyval.node) = mknode2(&node_bitand, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8056,7 +8059,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3418 "parser.y"
+#line 3420 "parser.y"
{(yyval.node) = mknode2(&node_bitxor, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8067,7 +8070,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3419 "parser.y"
+#line 3421 "parser.y"
{(yyval.node) = mknode2(&node_bitor, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8078,7 +8081,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3420 "parser.y"
+#line 3422 "parser.y"
{(yyval.node) = mknode2(&node_shr, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8089,7 +8092,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3421 "parser.y"
+#line 3423 "parser.y"
{(yyval.node) = mknode2(&node_ushr, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8100,7 +8103,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3422 "parser.y"
+#line 3424 "parser.y"
{(yyval.node) = mknode2(&node_shl, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8111,7 +8114,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3423 "parser.y"
+#line 3425 "parser.y"
{(yyval.node) = mknode2(&node_div, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8122,7 +8125,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3424 "parser.y"
+#line 3426 "parser.y"
{(yyval.node) = mknode2(&node_mod, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8133,7 +8136,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3425 "parser.y"
+#line 3427 "parser.y"
{(yyval.node) = mknode2(&node_plus, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8144,7 +8147,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3426 "parser.y"
+#line 3428 "parser.y"
{(yyval.node) = mknode2(&node_minus, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8155,7 +8158,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3427 "parser.y"
+#line 3429 "parser.y"
{(yyval.node) = mknode2(&node_multiply, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8166,7 +8169,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3428 "parser.y"
+#line 3430 "parser.y"
{(yyval.node) = mknode2(&node_in, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8177,7 +8180,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3429 "parser.y"
+#line 3431 "parser.y"
{(yyval.node) = mknode2(&node_as, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8188,7 +8191,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3430 "parser.y"
+#line 3432 "parser.y"
{(yyval.node) = mknode2(&node_instanceof, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8199,7 +8202,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3431 "parser.y"
+#line 3433 "parser.y"
{(yyval.node) = mknode2(&node_is, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8210,7 +8213,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3432 "parser.y"
+#line 3434 "parser.y"
{(yyval.node) = mknode1(&node_typeof, (yyvsp[(2) - (2)].node));}
}
break;
@@ -8221,7 +8224,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3433 "parser.y"
+#line 3435 "parser.y"
{(yyval.node) = mknode1(&node_void, (yyvsp[(2) - (2)].node));}
}
break;
@@ -8232,7 +8235,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3434 "parser.y"
+#line 3436 "parser.y"
{ (yyval.node) = mkconstnode(constant_new_undefined());}
}
break;
@@ -8243,7 +8246,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3435 "parser.y"
+#line 3437 "parser.y"
{ (yyval.node)=(yyvsp[(2) - (3)].node);}
}
break;
@@ -8254,7 +8257,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3436 "parser.y"
+#line 3438 "parser.y"
{(yyval.node) = mknode1(&node_neg, (yyvsp[(2) - (2)].node));}
}
break;
@@ -8265,7 +8268,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3437 "parser.y"
+#line 3439 "parser.y"
{(yyval.node) = mknode2(&node_arraylookup, (yyvsp[(1) - (4)].node),(yyvsp[(3) - (4)].node));}
}
break;
@@ -8276,7 +8279,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3438 "parser.y"
+#line 3440 "parser.y"
{(yyval.node) = mknode2(&node_muleq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8287,7 +8290,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3439 "parser.y"
+#line 3441 "parser.y"
{(yyval.node) = mknode2(&node_modeq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8298,7 +8301,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3440 "parser.y"
+#line 3442 "parser.y"
{(yyval.node) = mknode2(&node_shleq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8309,7 +8312,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3441 "parser.y"
+#line 3443 "parser.y"
{(yyval.node) = mknode2(&node_shreq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8320,7 +8323,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3442 "parser.y"
+#line 3444 "parser.y"
{(yyval.node) = mknode2(&node_ushreq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8331,7 +8334,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3443 "parser.y"
+#line 3445 "parser.y"
{ (yyval.node) = mknode2(&node_diveq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8342,7 +8345,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3444 "parser.y"
+#line 3446 "parser.y"
{ (yyval.node) = mknode2(&node_bitoreq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8353,7 +8356,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3445 "parser.y"
+#line 3447 "parser.y"
{ (yyval.node) = mknode2(&node_bitxoreq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8364,7 +8367,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3446 "parser.y"
+#line 3448 "parser.y"
{ (yyval.node) = mknode2(&node_bitandeq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8375,7 +8378,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3447 "parser.y"
+#line 3449 "parser.y"
{ (yyval.node) = mknode2(&node_pluseq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8386,7 +8389,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3448 "parser.y"
+#line 3450 "parser.y"
{ (yyval.node) = mknode2(&node_minuseq, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8397,7 +8400,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3449 "parser.y"
+#line 3451 "parser.y"
{ (yyval.node) = mknode2(&node_assign, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node));}
}
break;
@@ -8408,7 +8411,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3450 "parser.y"
+#line 3452 "parser.y"
{ (yyval.node) = mknode3(&node_tenary, (yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].node), (yyvsp[(5) - (5)].node));}
}
break;
@@ -8419,7 +8422,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3452 "parser.y"
+#line 3454 "parser.y"
{ (yyval.node) = mknode1(&node_rplusplus, (yyvsp[(1) - (2)].node));}
}
break;
@@ -8430,7 +8433,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3453 "parser.y"
+#line 3455 "parser.y"
{ (yyval.node) = mknode1(&node_rminusminus, (yyvsp[(1) - (2)].node));}
}
break;
@@ -8441,7 +8444,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3454 "parser.y"
+#line 3456 "parser.y"
{(yyval.node) = mknode1(&node_lplusplus, (yyvsp[(2) - (2)].node)); }
}
break;
@@ -8452,7 +8455,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3455 "parser.y"
+#line 3457 "parser.y"
{(yyval.node) = mknode1(&node_lminusminus, (yyvsp[(2) - (2)].node)); }
}
break;
@@ -8463,7 +8466,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3458 "parser.y"
+#line 3460 "parser.y"
{ if(!state->cls->info)
syntaxerror("super keyword not allowed outside a class");
classinfo_t*t = state->cls->info->superclass;
@@ -8486,7 +8489,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3472 "parser.y"
+#line 3474 "parser.y"
{
typedcode_t v;
multiname_t m = {MULTINAMEA, 0, &nopackage_namespace_set, (yyvsp[(2) - (2)].id)};
@@ -8503,7 +8506,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3480 "parser.y"
+#line 3482 "parser.y"
{PASS12 new_state();state->xmlfilter=1;}
}
break;
@@ -8514,7 +8517,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3480 "parser.y"
+#line 3482 "parser.y"
{
PASS1 old_state();
PASS2
@@ -8577,7 +8580,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3534 "parser.y"
+#line 3536 "parser.y"
{(yyval.id)=(yyvsp[(1) - (1)].id);}
}
break;
@@ -8588,7 +8591,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3535 "parser.y"
+#line 3537 "parser.y"
{(yyval.id)="*";}
}
break;
@@ -8599,7 +8602,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3537 "parser.y"
+#line 3539 "parser.y"
{(yyval.id)="*";}
}
break;
@@ -8610,7 +8613,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3577 "parser.y"
+#line 3579 "parser.y"
{
(yyval.node) = get_descendants((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(5) - (5)].id), 0, 0);
}
@@ -8623,7 +8626,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3580 "parser.y"
+#line 3582 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (3)].node));
multiname_t m = {MULTINAME, 0, &nopackage_namespace_set, (yyvsp[(3) - (3)].id)};
@@ -8640,7 +8643,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3587 "parser.y"
+#line 3589 "parser.y"
{
(yyval.node) = get_descendants((yyvsp[(1) - (5)].node), (yyvsp[(3) - (5)].id), (yyvsp[(5) - (5)].id), 1, 0);
}
@@ -8653,7 +8656,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3590 "parser.y"
+#line 3592 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (5)].node));
typedcode_t w = node_read((yyvsp[(4) - (5)].node));
@@ -8673,7 +8676,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3601 "parser.y"
+#line 3603 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (4)].node));
multiname_t m = {MULTINAMEA, 0, &nopackage_namespace_set, (yyvsp[(4) - (4)].id)};
@@ -8690,7 +8693,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3609 "parser.y"
+#line 3611 "parser.y"
{
(yyval.node) = get_descendants((yyvsp[(1) - (6)].node), (yyvsp[(4) - (6)].id), (yyvsp[(6) - (6)].id), 0, 1);
}
@@ -8703,7 +8706,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3613 "parser.y"
+#line 3615 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (4)].node));
multiname_t m = {MULTINAMEA, 0, &nopackage_namespace_set, (yyvsp[(4) - (4)].id)};
@@ -8720,7 +8723,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3620 "parser.y"
+#line 3622 "parser.y"
{
(yyval.node) = get_descendants((yyvsp[(1) - (6)].node), (yyvsp[(4) - (6)].id), (yyvsp[(6) - (6)].id), 1, 1);
}
@@ -8733,7 +8736,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3624 "parser.y"
+#line 3626 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (6)].node));
typedcode_t w = node_read((yyvsp[(5) - (6)].node));
@@ -8753,7 +8756,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3634 "parser.y"
+#line 3636 "parser.y"
{
typedcode_t v = node_read((yyvsp[(1) - (6)].node));
typedcode_t w = node_read((yyvsp[(5) - (6)].node));
@@ -8773,7 +8776,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3645 "parser.y"
+#line 3647 "parser.y"
{
typedcode_t v1 = node_read((yyvsp[(1) - (3)].node));
(yyval.value).c = v1.c;
@@ -8847,7 +8850,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3841 "parser.y"
+#line 3844 "parser.y"
{
PASS1
/* Queue unresolved identifiers for checking against the parent
@@ -8879,7 +8882,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3875 "parser.y"
+#line 3878 "parser.y"
{
PASS12
NEW(namespace_decl_t,n);
@@ -8896,7 +8899,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3882 "parser.y"
+#line 3885 "parser.y"
{
PASS12
NEW(namespace_decl_t,n);
@@ -8913,7 +8916,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3889 "parser.y"
+#line 3892 "parser.y"
{
PASS12
NEW(namespace_decl_t,n);
@@ -8930,7 +8933,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3896 "parser.y"
+#line 3899 "parser.y"
{
PASS12
dict_put(state->namespaces, (unsigned char*)(yyvsp[(2) - (2)].namespace_decl)->name, (void*)(yyvsp[(2) - (2)].namespace_decl)->url);
@@ -8961,7 +8964,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3919 "parser.y"
+#line 3922 "parser.y"
{
(yyval.code) = 0;
(yyval.code) = code_append((yyval.code), node_read((yyvsp[(4) - (4)].node)).c);
@@ -8976,7 +8979,7 @@ PASS12
if(as3_pass==2) {
/* Line 1464 of skeleton.m4 */
-#line 3925 "parser.y"
+#line 3928 "parser.y"
{
PASS12
@@ -9004,7 +9007,7 @@ PASS12
/* Line 1464 of skeleton.m4 */
-#line 9008 "parser.tab.c"
+#line 9011 "parser.tab.c"
default: break;
}
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
diff --git a/lib/as3/pool.c b/lib/as3/pool.c
index 3889ee64..4cd4352e 100644
--- a/lib/as3/pool.c
+++ b/lib/as3/pool.c
@@ -1359,13 +1359,17 @@ void pool_write(pool_t*pool, TAG*tag)
} else {
assert(m->type!=0x07 && m->type!=0x0d);
}
+
if(m->name) {
assert(m->type==0x09 || m->type==0x0e || m->type==0x07 || m->type==0x0d || m->type==0x0f || m->type==0x10);
int i = pool_find_string(pool, m->name);
if(i<0) fprintf(stderr, "internal error: unregistered name\n");
swf_SetU30(tag, i);
} else {
- assert(m->type!=0x09 && m->type!=0x0e && m->type!=0x07 && m->type!=0x0d && m->type!=0x0f && m->type!=0x10);
+ if(m->type == 0x09) {
+ swf_SetU30(tag, 0);
+ }
+ assert(m->type!=0x0e && m->type!=0x07 && m->type!=0x0d && m->type!=0x0f && m->type!=0x10);
}
if(m->namespace_set) {
assert(m->type==0x09 || m->type==0x0e || m->type==0x1c || m->type==0x1b);