Граф коммитов

3686 Коммитов

Автор SHA1 Сообщение Дата
jband%netscape.com 02986411d1 fix bug 96511. Meant #ifdef not #if. sr=brendan r=jband 2001-09-06 19:01:17 +00:00
nboyd%atg.com a14d6d33c5 patch (with my modifications) from jj@mail.ahc.umn.edu:
It would be nice if the rhino shell would accept a URL as the source
for javascript.

I've added this feature to my local copy so that I can launch rhino
with js scripts using  JavaWebStart.

Below is a context diff of the changes I made to
toolsrc/org/mozilla/javascript/tools/shell/Main.java
2001-09-06 16:53:29 +00:00
jband%netscape.com 0a93bb62fa fix bug 98450. We need to be calling OBJ_DROP_PROPERTY after OBJ_LOOKUP_PROPERTY. Also, this was refactored on dbradley's suggestion. sr=brendan r=dbradley 2001-09-06 06:29:19 +00:00
rginda%netscape.com 49273bb507 - venkman only -
init xpconnect on the debugger's default context so that xpconnect can use it when it has to.  r=jband
2001-09-06 01:34:44 +00:00
pschwartau%netscape.com 082245971f Trivial whitespace fix. 2001-09-05 23:35:07 +00:00
pschwartau%netscape.com ed10eb7850 Completely rethinking this testcase. Reduced test as much as possible, added try...catch blocks and for-loop to stress-test the code. 2001-09-05 23:21:33 +00:00
rginda%netscape.com ea08067f65 - venkman only -
turn off verbose debugging for me
push a thread event queue for necko before we enter a nested event loop
2001-09-05 21:29:59 +00:00
jband%netscape.com 23d7dc717d fix bug 97444. It is not good to patch a different fun into the frame. Let's safely shunt aside the callee frame instead. r=rogerl sr=brendan 2001-09-05 21:25:09 +00:00
pschwartau%netscape.com 8873ed636b Improved accuracy of test, and added more cases. 2001-09-05 21:15:43 +00:00
pschwartau%netscape.com 4380531bc9 Adding comment regarding regress-97646-001-n.js, regress-97646-002-n.js 2001-09-05 17:47:11 +00:00
pschwartau%netscape.com a42722d0e6 Correcting comments at top of file, plus bug and summary values. 2001-09-05 17:13:14 +00:00
pschwartau%netscape.com 4757b4fc39 Correcting date at top of file. 2001-09-05 17:03:32 +00:00
pschwartau%netscape.com 87765e762a Correcting comments at top of file, plus bug and summary values. 2001-09-05 17:01:03 +00:00
nboyd%atg.com 4e39e826e2 Patch from Igor. 2001-09-05 16:54:37 +00:00
nboyd%atg.com 8eb4d39793 Patch from jeffh@aiinet.com:
There is a bug in the JavaMembers class called to wrap a Java object.

In JavaMembers.lookup(), code was added to override the static type.  The
code works in the case of an Enumeration returning an Object which would
have to be casted to the appropriate type.

The code does not work when the static type is an interface.  In this case,
the interface class is the one which should be reflected, not a parent class
of the dynamic type.  A simple staticType.isInterface() check around the
parent traversal code fixes the problem.

Jeff
2001-09-05 16:52:39 +00:00
nboyd%atg.com a19d5beda6 Patch from jeffh@aiinet.com:
I have found a couple problems with running Rhino 1.5R2 in a heavily
multi-threaded environment.  The attached patches fix the problems.

- org.mozilla.javascript.optimizer.InvokerImpl - This class was accessing
the shared classNumber outside of the synchronized block.

- org.mozilla.javascript.optimizer.OptClassNameHelper - The reset method was
not synchronized.  It needs to be because the class using the classNames map
is synchronized and does not handle nulling of the variable while it's
looping on the map.

Jeff
2001-09-05 16:50:26 +00:00
nboyd%atg.com 4507a1cf73 Update for new tests. 2001-09-05 16:48:31 +00:00
pschwartau%netscape.com cb11cb7e47 Initial add. Regression test for bug 98306. 2001-09-05 06:27:25 +00:00
pschwartau%netscape.com 0b02e3b978 Skipping two new tests that use non-EMCA functionality: toSource() and uneval(). 2001-09-05 01:07:17 +00:00
pschwartau%netscape.com ded8f34015 Improved readabilty. Improved accuracy of stripBraces() function. 2001-09-05 00:49:31 +00:00
pschwartau%netscape.com 018096156d This is more accurate. Also using sorting now, for definiteness in comparisons. 2001-09-05 00:46:24 +00:00
pschwartau%netscape.com 3e130a22c8 Initial add. Regression test for bug 96284. 2001-09-04 01:54:36 +00:00
brendan%mozilla.org 622522e134 Ignore property found in non-native prototype (12367, sr=jband&shaver, a=asa). 2001-09-03 22:29:12 +00:00
brendan%mozilla.org 0cf73f1847 Fix toSource on exception objects so it uses toSource to generate properly-quoted, embedded string literals for message and filename (bug 96284, r=jband, sr=shaver, a=asa). 2001-09-03 19:36:24 +00:00
rginda%netscape.com f14e08526e bug 88130, patch=jband, r=me,dbradley, sr=jst, a=brendan
clear exception state before and after calling out via xpconnect.
remove redundant exception clear from CallQueryInterfaceOnJSObject.
2001-09-01 22:47:47 +00:00
rginda%netscape.com c5226cb4b5 -- not built --
exposing call hook functionality
2001-09-01 18:03:53 +00:00
rginda%netscape.com 95a185d386 -- not built --
whitespace cleanup
2001-09-01 18:01:28 +00:00
jband%netscape.com 56d03ab63d fix bug 97555. Need to get the correct value of staep into the iterator object when we fail during enumeration init. r=jst sr=brendan a=asa 2001-08-31 21:48:18 +00:00
brendan%mozilla.org 43c254feee Fix 97540, r=rginda, sr=jband, a=asa:
- The most significant fix, to keep JSStackFrame.spbase, the operand stack base pointer for an active frame, null except when there is an operand stack allocated and in use by js_Interpret.  Previously, spbase would point after args and local vars (if any), then advance upon allocation of the (possibly discontiguous) operand stack space.  This made for a fatal ambiguity: js_AllocStack, called by XPConnect, could not tell when there was allocated operand stack space above the frame's sp, which needs to be set to a known (JSVAL_VOID) state for exact GC to work.  Now, the GC doesn't have to mark any operand stack space for a frame whose spbase is null, and js_AllocStack doesn't need to void any unused space for such a frame.

- Fixes to reload the JSRuntime's callHook or executeHook after calling or executing, in case the debugger removes the hook.  In which case, it must clean up any dynamic memory held by hookData, but in any event, in which case the engine must not call the post-call or post-execute hook.

- While debugging with rginda, I was horrified to see his trivial testcase function, expressed as a lambda, fail to be invoked using the "inline_call" machinery in js_Interpret (which avoids js_Interpret recursion through js_Invoke for most JS functions).  The problem was a test of fun->flags == 0 conditioning the /* inline_call: */ code.  Since that test was written, at least one JSFUN_* flag (JSFUN_LAMBDA, used only for pretty-printing or accurate decompilation) has been added.  But all along, that test was an over-optimization (testing against 0 without &'ing certain flags), making for an accident waiting to happen -- which did happen.  The relevant flags are JSFUN_HEAVYWEIGHT (set by the compiler when a function calls eval, uses with, or otherwise needs an activation object for its scope; if lightweight, the compiler can see the function's scope and eliminate it via specialized bytecodes) and JSFUN_BOUND_METHOD (for Java method calls, where |this| binds statically to the instance, not dynamically to the calling expression reference's base object, as in JS).
2001-08-31 21:25:26 +00:00
pschwartau%netscape.com f37dffb52a Corrected testcase so it will work in Rhino as well as SpiderMonkey. 2001-08-31 06:10:13 +00:00
pschwartau%netscape.com d3d0f5e05a Initial add. 2001-08-30 19:55:05 +00:00
pschwartau%netscape.com e456fc4d42 Trivial whitespace change. 2001-08-29 23:34:32 +00:00
pschwartau%netscape.com 42fca7b54a Initial add. 2001-08-29 23:20:16 +00:00
pschwartau%netscape.com 36ee37b5de Removed a few hundred || conditions. See comment 2001-08-29 12:00 in bug 89443. 2001-08-29 20:37:58 +00:00
pschwartau%netscape.com 1842238b89 Adding skips for two tests employing the non-ECMA toSource() and uneval() functions. 2001-08-29 06:14:38 +00:00
pschwartau%netscape.com cf7115e693 Initial add. 2001-08-29 05:59:52 +00:00
rginda%netscape.com 6835cdd75e - not built -
spruce up some comments
added, then comented out, jsdIDebuggerService::filterGlobalObject
2001-08-28 22:03:44 +00:00
rginda%netscape.com 7d148030f7 - not built -
whitespace tweakage
2001-08-28 22:02:28 +00:00
rginda%netscape.com 4f4bb7a28f - not built -
don't allow gc's during script hooks if CAUTIOUS_SCRIPTHOOK is defined (which it is, by default.)  Should help with stability until we can fix the real problems.
Use JSVAL_ macros instead of JSD_* calls in jsdValue::GetJSType method, avoiding two c++ frames per call.
2001-08-28 22:02:07 +00:00
rginda%netscape.com 7cb5a48149 - not built -
modeline fix
2001-08-28 21:59:53 +00:00
jband%netscape.com f95e84e0e7 fix bug 96725. Avoid infinite recursion in call to QI'd xbl binding by avoiding the mutation of the interface set when the object implementing the interface is a wrappedJS around our wrappedNative's own JSObject. r=dbradley sr=hyatt a=brendan,hyatt,jband 2001-08-28 21:52:10 +00:00
pschwartau%netscape.com 09987595a3 Adding two new utility functions. 2001-08-28 21:13:58 +00:00
thesteve%netscape.com aee3db86dc Bug#81373 (mac static build)
fixed up access paths: get rid of :::dist:client[_debug]
r=jfrancis
sr=sfraser
a=asa on behalf of drivers
2001-08-27 23:45:59 +00:00
pschwartau%netscape.com 7dcd878d8f Punctuation correction in comment. 2001-08-27 22:57:25 +00:00
pschwartau%netscape.com f055101da4 Initial add. 2001-08-27 22:55:57 +00:00
pschwartau%netscape.com c7e5cb06a4 Some RegExp bugs have now been fixed in Rhino. Removing the testcases from the skip list. 2001-08-27 19:58:56 +00:00
rogerl%netscape.com b16d847568 Port of performance fixes from Monkey (see bug #85721).
Also, fixes for :
#91343, (non-latin1 fails for [\S])
#78156, (Unicode line terminator matching)
#87231, (/(A)?(A.*)/ didn't reset paren state for empty first match)
2001-08-27 18:03:19 +00:00
rjesup%wgate.com 6f3e4115eb Bug 94243: VoidArray usage patch. a=asa sr=brendan r=waterson r=bienvenu
r=pierre r=jband/dbradley  Also fixes some whitespace issues.
2001-08-27 06:15:54 +00:00
pschwartau%netscape.com 9e09712d1e Technical change. Now test is accurate for Rhino as well as SpiderMonkey. 2001-08-25 05:01:50 +00:00
nboyd%atg.com 115380ea02 Original problem in following mail. I implemented JDK1.1 compatibility and performance
improvements:

Subject:
        Rhino: Problem in NativeJavaMethod
   Date:
        Tue, 14 Aug 2001 10:23:35 +0200
   From:
        felix.meschberger@day.com
     To:
        Norris Boyd <nboyd@atg.com>




Hi Norris,

While working with wrapped Java classes we discovered a problem in
NativeJavaMethod : If the public method to be called is part of a
non-public class, the Sun Java VM throws an IllegalAccessException. This
bug in the Sun VM has been reported as Bug 4071593 to Sun, but has not been
resolved since....

I implemented a circumvention, for which I provide you the patch. I quickly
tested it, and it seems to work.

Regards
Felix

And here's the patch :

diff -w -r1.19 NativeJavaMethod.java
227a228,234
>        /**
>         * Due to a bug in Suns VM, public methods in private
>         * classes are not accessible by default (Sun Bug #4071593).
>         * We have to explicitly set the method accessible beforehand
>         */
>        meth.setAccessible(true);
>

-----------------------------------------------------------------
This message is a private communication. If you are not the intended
recipient, please do not read, copy, or use it, and do not disclose it
to others. Please notify the sender of the delivery error by replying to
this message, and then delete it from your system. Thank you.
The sender does not assume any liability for timely, trouble-free,
complete, virus free, secure, error free or uninterrupted arrival of
this e-mail. For verification please request a hard copy version.

mailto:felix.meschberger@day.com
http://www.day.com

Felix Meschberger
Development
Day Interactive AG
Steinenberg 21-23
4001 Basel
Switzerland

T  41 61 226 98 98
F  41 61 226 98 97
2001-08-24 20:01:49 +00:00