Hi Fabian, Today I downloaded Qx 0.6.6 and found the same bug occurring.
Here's what I did: 1. Downloaded qx 0.6.6 sdk. 2. Copied some of my project source code into a new "skeleton like" demo project. 3. Ran the migration script from 0.6.5 to 0.6.6 on the new demo project. 4. Ran make source 5. Tested the demo app in FF -- clone() worked 6. Ran make build 7. Tested the demo app in FF -- clone() failed I've attached a copy of my demo project for you to test -- qooxdoo-apps-0-6-6.foo. You will have to rename the attached file to qooxdoo-apps-0-6-6.zip (since sf won't let me attach a .zip file). Inside you should find a trivial demo project called "clone-bug-demo". If you build it with the 0.6.6 sdk you should see the bug I am seeing. Hope this helps :) Simon p.s. This problem is only academic for me, since we are no longer using clone() because it is slow and memory hungry. But perhaps this bug might be a real problem for someone else in the future? ----- Original Message ---- From: Fabian Jakobs <[EMAIL PROTECTED]> To: qooxdoo Development <qooxdoo-devel@lists.sourceforge.net> Sent: Friday, 23 March, 2007 6:53:08 PM Subject: Re: [qooxdoo-devel] Possible bug in make build? Simon Bull schrieb: > Hi All, > > I am using Qx 0.6.5. > > I have a custom js class called ViewState that is composed of ViewCategories, > which are composed of OptionGroups, which are composed of Options. Each of > these classes implements a clone method that looks something like this (this > one is from the top level Object, ViewState): > > qx.Proto.clone = function() > { > var cloneArgs = {}; > cloneArgs.viewCategories = []; > var vcs = this.getViewCategories(); > for (var i = 0; i < vcs.length; i++) > { > var vc = vcs[i]; > if (vc != null) > { > var cloneViewCategory = vc.clone(); > cloneArgs.viewCategories[cloneArgs.viewCategories.length] = > cloneViewCategory; > } > } > var clone = new ext.data.viewstate.ViewState(cloneArgs); > return clone; > } > > > My code runs fine after a make source, but fails after a make build. Looking > into the custom.js file I see that lines of code like: > > var clone = new ext.data.viewstate.ViewState(cloneArgs); > > are compressed to: > > var $b = new ext.data.viewstate.ViewState($a); > > which is all good. > > > However, some (not all) of the lines of code that look like: > > var cloneViewCategory = vc.clone(); > > are compressed to: > > var $c = $d.$b(); > > > which is wrong, it should something like: > > var $c = $d.clone(); > > > If I change the source code from > "var clone = new ext.data.viewstate.ViewState(cloneArgs);" > > to > > "var foobar = new ext.data.viewstate.ViewState(cloneArgs);" > > then both the make source and make build versions work fine. > > It appears that the make script is confusing the local var name "clone" with > the method name "clone". Perhaps this is related to the recursive nature of > my clone() method? > > > Has anyone else seen this problem? > > > Simon > Hello Simon, this looks loke a bug in the local variable optimizer. I'll have a look on this and try to reproduce it here. best Fabian P.S. If you find issues like this, don't hasitate to open a bug in the bugzilla :-) ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel Send instant messages to your online friends http://au.messenger.yahoo.com
qooxdoo-apps-0-6-6.foo
Description: Binary data
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel