[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] /srv/bzr/gnash/avm2 r9590: Correctly access an object's p
From: |
Tom Stellard |
Subject: |
[Gnash-commit] /srv/bzr/gnash/avm2 r9590: Correctly access an object's prototype, and other small improvements. |
Date: |
Sun, 05 Oct 2008 21:07:54 +0800 |
User-agent: |
Bazaar (1.5) |
------------------------------------------------------------
revno: 9590
committer: Tom Stellard <address@hidden>
branch nick: gnash_dev
timestamp: Sun 2008-10-05 21:07:54 +0800
message:
Correctly access an object's prototype, and other small improvements.
modified:
testsuite/actionscript.all/haxe-swf9/as_to_hx.pl
=== modified file 'testsuite/actionscript.all/haxe-swf9/as_to_hx.pl'
--- a/testsuite/actionscript.all/haxe-swf9/as_to_hx.pl 2008-10-05 00:17:02
+0000
+++ b/testsuite/actionscript.all/haxe-swf9/as_to_hx.pl 2008-10-05 13:07:54
+0000
@@ -13,7 +13,6 @@
#CHECK 0
#Remove rcsid, I think makeSWF uses this, but I am not sure.
if(index($_,"rcsid=") != $[-1){
- skip_line();
next;
}
@@ -107,9 +106,9 @@
skip_line();
next;
}
- #Replace instanceof:
- #TODO: Implement
- if(index($_,"typeof") != $[-1){
+ #Replace typeof:
+ #TODO: Figure out the difference between typeof and typeOf
+ if($_ =~ /type[Oo]f/ ){
skip_line();
next;
}
@@ -135,8 +134,9 @@
next;
}
if(index($_,"prototype") != $[-1){
- skip_line();
- next
+ $_ =~ s/(\w+)\.(prototype)/Reflect.field($1,\'$2\')/g;
+# skip_line();
+# next
}
if(index($_,"isNaN") != $[-1){
# $_ =~ s/(isNaN)/Math\.$1/g;
@@ -234,6 +234,17 @@
next;
}
+ #Object is not a valid type in Haxe.
+ if($_ =~ /Object/){
+ skip_line();
+ next;
+ }
+
+ #Remove calls to ASSetPropFlags. I can't find a Haxe equivilent.
+ if($_ =~ /ASSetPropFlags/){
+ skip_line();
+ next;
+ }
#Print the converted line of code.
print $_;
}
- [Gnash-commit] /srv/bzr/gnash/avm2 r9590: Correctly access an object's prototype, and other small improvements.,
Tom Stellard <=