Subj : Re: Limit of lines of JS-Code? To : danielkirsch From : Brendan Eich Date : Thu Jun 02 2005 11:48 am Daniel Kirsch wrote: > We created a pretty large project (based on Firefox 1.0.3 code) with > many JavaScript files and dynamically created JavaScript objects from > hundreds of parsed XML files. > > We now run into a pretty strange problem. When writing additional lines > of code some methods cannot be called anymore. Calling them throws an > exception. > We found out that it doesn't matter in which file we add additional code > or even blank lines. We get it down to one single line-break which > causes the problem. When we remove the line-break everything works. Please file a bug at https://bugzilla.mozilla.org/ and attach the minimal testcase. Product: Core, Component: JavaScript Engine. > Is there any known limit of how many lines of javascript code can be > used for a XUL project? This does not sound like a line count limit. > We had similar behaviours before which could be solved by adding or > removing some blank lines (!) in a document. The error seems to depend > on a document. Not a special one but randomly on any document we > recently changed. But this time it seems, as if there is a character > limit and it doesn't matter which file contains the additional character. That's odd. > Any ideas for a workaround? Not without a bug with a reproducible testcase attached. Major bonus points if you can get this to reproduce using just js shell or xpcshell. /be .