ok I found the reason below why my class compiles on CS3and not MTASC.ThanksFranckHi,
With Flash 8, when class size exceeds 32k, MMC adds a jump extending the cjump at the start of class def, if possible (that is, if there's a space between functions -and there are more than one function in the first place). Of course, this doesn't help with large data... BTW, function size is stated as *unsigned* 16 bit in SWF specs - though I haven't checked if it actually is. Best regards, Burak Burak KALAYCI, Manitu Group http://www.buraks.com http://www.manitugroup.com ----- Original Message ----- From: "Nicolas Cannasse" <ncannasse at motion-twin.com> To: "MotionTwin ActionScript2 Compiler List" <mtasc at lists.motion-twin.com> Sent: Friday, March 31, 2006 10:16 AM Subject: Re: [mtasc] 32k limit vs large data classes >> A page from macromedia states that: >> >> "[...]This comes from a limitation in the Flash Player with the SWF file >> format. Branches cannot be more than +/- 32k, and functions cannot be >> longer than 64k.[...]" >> >> That's 64k, not 32k... Probably the size of a function is not "signed" >> after all? > > Possible. > >> That could explain why some large classes compiles with MMC but not with >> MTASC. > > If some classes compiles with MMC and not with MTASC, that simply means > that MMC let you compile an invalid branch, since all classes are > defined this way (in pseudo-bytecode) : > > eval "MyClass" > not > not > cjump already_defined > // class definition > already_defined: > > So the entire class must be lower than 32K, or else if the class is > already defined the jump will go backwards, with a possibility of > creating an infinite loop. > > Nicolas > _______________________________________________ osflash mailing list [email protected] http://osflash.org/mailman/listinfo/osflash_osflash.org
