gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] /srv/bzr/gnash/trunk r10418: Add what would be the perfec


From: Sandro Santilli
Subject: [Gnash-commit] /srv/bzr/gnash/trunk r10418: Add what would be the perfect candidate to be encoded as a STRICT_ARRAY, and test that it's still encoded as an ECMA_ARRAY instead.
Date: Sun, 14 Dec 2008 00:02:52 +0100
User-agent: Bazaar (1.5)

------------------------------------------------------------
revno: 10418
committer: Sandro Santilli <address@hidden>
branch nick: trunk
timestamp: Sun 2008-12-14 00:02:52 +0100
message:
  Add what would be the perfect candidate to be encoded as a STRICT_ARRAY, and 
test that it's still encoded as an ECMA_ARRAY instead.
modified:
  testsuite/misc-ming.all/SharedObjectTest.as
  testsuite/misc-ming.all/SharedObjectTest.sol/sol1.sol
=== modified file 'testsuite/misc-ming.all/SharedObjectTest.as'
--- a/testsuite/misc-ming.all/SharedObjectTest.as       2008-09-15 11:07:42 
+0000
+++ b/testsuite/misc-ming.all/SharedObjectTest.as       2008-12-13 23:02:52 
+0000
@@ -85,6 +85,11 @@
 a.sort();
 check_equals(a.toString(), '0,1,2,custom'); // note: no 'length'
 
+// Test reading STRICT_ARRAY
+check_equals(typeof(so1.data.strictary), 'object');
+check_equals(so1.data.strictary.toString(), 'a,b,c');
+check_equals(so1.data.strictary.length, 3);
+
 // Test reading OBJECT
 check(so1.data.obj instanceOf Object);
 check_equals(typeof(so1.data.obj), 'object');
@@ -129,6 +134,13 @@
 so1.data.aryns.custom = 7;
 so1.data.aryns.length = 8; // non-strict array (ECMA_ARRAY)
 
+// This member is an attempt to trigger encoding
+// of a STRICT array. The attempt seems to be
+// unsuccessful tough, but no way to test with 
+// ActionScript. Time to look at the binary differences
+// between the pp and gnash versions of the saved sol.
+so1.data.strictary = ['a','b','c'];
+
 so1.data.obj = {a:10,b:'20',c:true};
 so1.data.obj.fun = function() {}; // functions in objects are simply skipped
 so1.data.obj.mc = createEmptyMovieClip("mc1", 1); // movieclip values are 
skipped
@@ -164,4 +176,4 @@
 setInterval(quit, 5000);
 stop();
 
-check_totals(38);
+check_totals(41);

=== modified file 'testsuite/misc-ming.all/SharedObjectTest.sol/sol1.sol'
Binary files a/testsuite/misc-ming.all/SharedObjectTest.sol/sol1.sol    
2008-09-14 17:11:51 +0000 and 
b/testsuite/misc-ming.all/SharedObjectTest.sol/sol1.sol   2008-12-13 23:02:52 
+0000 differ

reply via email to

[Prev in Thread] Current Thread [Next in Thread]