igor%mir2.org
c66294544a
Added ScriptableObject.equivalentValues to allow for custom equality operator support.
...
git-svn-id: svn://10.0.0.236/trunk@159979 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 15:23:11 +00:00
igor%mir2.org
f2d7f8a543
Added Reference.has() for future use.
...
git-svn-id: svn://10.0.0.236/trunk@159978 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 15:21:02 +00:00
igor%mir2.org
cae761c1ee
Ignore any exception during script class initialization unless it is an instance of RhinoException. In this way lazily class loading or incompatible with the current JVMs jars will simply hide the script variables.
...
git-svn-id: svn://10.0.0.236/trunk@159977 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 15:20:08 +00:00
igor%mir2.org
2c01e9ba15
Always call Scriptable.has(name, start) as obj.has(name, obj) since the start argument is useless in Scriptable.has and in this way it is possible to add temporary assertions to the code checking this.
...
git-svn-id: svn://10.0.0.236/trunk@159975 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 13:27:39 +00:00
igor%mir2.org
431020ede7
Redesigning IdScriptable implementation.
...
The new logic introduces 2 independent id namespaces, instance ids and prototype ids. Typically there are very few instance properties and instance ids corresponds exactly to them. The prototype ids allows to define functions and other constant objects that typically found in prototype objects.
The new implementation takes advantage of this difference to provide very different API to implement fast mapping both for instance and prototype ids.
git-svn-id: svn://10.0.0.236/trunk@159974 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 11:40:38 +00:00
igor%mir2.org
de1171b960
Introduction of defaultParentScope and defaultPrototype in ScriptableObject for lazily initialization of scope and prototype.
...
git-svn-id: svn://10.0.0.236/trunk@159973 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 09:52:29 +00:00
igor%mir2.org
461207c7c8
Making ScriptRuntime.typeError* public
...
git-svn-id: svn://10.0.0.236/trunk@159972 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 09:51:02 +00:00
igor%mir2.org
6498310596
Allow to subclass NativeWith
...
git-svn-id: svn://10.0.0.236/trunk@159971 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 09:50:07 +00:00
igor%mir2.org
bec0ec22ba
Favour same type converssions during LiveConnect for better support of java methods taking instances of Scriptable
...
git-svn-id: svn://10.0.0.236/trunk@159970 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 09:49:19 +00:00
igor%mir2.org
fb39e27895
1. Optimizing getClassPrototype and getDefaultValue in ScriptableObject.
...
2. Start of the changes for simpler to use IdScriptable implementation: new utility functions in IdFunction and removal of Context argument from IdScriptable.fillConstructorProperties.
git-svn-id: svn://10.0.0.236/trunk@159966 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 07:12:46 +00:00
igor%mir2.org
4055375f9f
Context.getArrayElements implementation is moved to ScriptRuntime which also defined now isArrayObject
...
git-svn-id: svn://10.0.0.236/trunk@159964 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-28 07:06:35 +00:00
brendan%mozilla.org
f7b9ce6db4
Avoid harmless UMC from purify when XDR-decoding (252047, r=shaver).
...
git-svn-id: svn://10.0.0.236/trunk@159893 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-27 01:28:39 +00:00
mkaply%us.ibm.com
d924b7872b
This stuff doesn't work on OS/2 and is causing thousands of warnings errors
...
git-svn-id: svn://10.0.0.236/trunk@159688 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-22 20:27:48 +00:00
brendan%mozilla.org
6b7f7ecdc5
Update map->freeslot in js_SetRequiredSlot if obj has its own scope (245890, r=shaver); also clear pending exceptions as needed in js_TryMethod (old unreported bug, r=self).
...
git-svn-id: svn://10.0.0.236/trunk@159660 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-22 15:47:22 +00:00
timeless%mozdev.org
4e31823e07
reverting 3.176 per brendan
...
git-svn-id: svn://10.0.0.236/trunk@159538 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-20 16:11:53 +00:00
brendan%mozilla.org
dc606d6d85
Fix unused variable problem.
...
git-svn-id: svn://10.0.0.236/trunk@159382 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-17 02:44:37 +00:00
brendan%mozilla.org
c7bb7a454c
- Add JS_Has*Property and JS_HasElement APIs, for unambiguous testing of whether an object or one of its prototypes has an identified property.
...
- Add JS_ReportPendingException, and fix its js_ReportUncaughtException subroutine to (a) not return false on vacuous success; (b) fail to clear the pending exception it reports.
git-svn-id: svn://10.0.0.236/trunk@159381 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-17 02:39:55 +00:00
brendan%mozilla.org
9d3428574c
White space policing.
...
git-svn-id: svn://10.0.0.236/trunk@159380 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-17 02:31:11 +00:00
tor%cs.brown.edu
61fec9ef22
Bug 165200 - Number.toLocaleString() localization. r=brendan
...
git-svn-id: svn://10.0.0.236/trunk@159366 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-16 21:17:50 +00:00
timeless%mozdev.org
1dde0401e3
Bug 243869 js_ReportUncaughtException doesn't propagate filename/lineno from error object
...
These changes are a last ditch effort to provide filename info for certain failures.
r=shaver
git-svn-id: svn://10.0.0.236/trunk@159346 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-16 17:30:23 +00:00
brendan%mozilla.org
53f0bf3fa1
Restore export/import support for 4.x signed script compatibility (249211, r=self).
...
git-svn-id: svn://10.0.0.236/trunk@159272 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-15 19:21:35 +00:00
brendan%mozilla.org
9edbb0b2c1
Improve JSRESOLVE_DETECTING by treating 'terminal' uses of, e.g., document.all as detecting (248549, r=jst).
...
git-svn-id: svn://10.0.0.236/trunk@159266 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-15 18:53:59 +00:00
dbaron%dbaron.org
6ba6a78f8e
Only use __attribute__ on gcc 3 or higher. Fixing bustage. b=249652
...
git-svn-id: svn://10.0.0.236/trunk@159221 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-15 00:00:43 +00:00
bryner%brianryner.com
e372b2e9a3
Add a NS_FASTCALL macro that specifies regparm(3) and stdcall on gcc/x86 to improve performance (passing up to 3 arguments in registers instead of on the stack, and having the caller pop any stack arguments). Apply NS_FASTCALL to our most frequently called non-public methods and functions. Also add NS_CDECL to explicitly specify the default calling convention and make it part of NS_IMETHOD, since xptcall can't deal with NS_FASTCALL. Bug 249652, r=darin, sr=dbaron.
...
git-svn-id: svn://10.0.0.236/trunk@159199 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-14 22:14:34 +00:00
igor%mir2.org
3dae56ac7c
Making next release to be 1.6 release 1
...
git-svn-id: svn://10.0.0.236/trunk@159057 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-12 14:26:30 +00:00
igor%mir2.org
dec8ae36c7
Renaming ObjArray.setReadOnly() to ObjArray.seal() to follow the rest of Rhino code.
...
git-svn-id: svn://10.0.0.236/trunk@158942 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-09 13:28:48 +00:00
igor%mir2.org
ba01b2ec28
Fixing comments text to reflect real state of code
...
git-svn-id: svn://10.0.0.236/trunk@158856 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-07 14:47:46 +00:00
igor%mir2.org
e2d5a19c1a
Almost reverting the prevois commit: it was too preliminary.
...
git-svn-id: svn://10.0.0.236/trunk@158855 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-07 14:46:58 +00:00
brendan%mozilla.org
0e385c551c
Enhance RegExp.prototype.to{Source,String} to escape naked slashes in the regexp source (284444, r=shaver).
...
git-svn-id: svn://10.0.0.236/trunk@158824 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-07 03:58:26 +00:00
igor%mir2.org
571edfd25e
Changing the way Java getter and setter are stored: a new special class ComplexValue is used to indicate a controllable value that may have associated getter/setter methods. In this way getter can be added after slot creation without the need to replace slots.
...
git-svn-id: svn://10.0.0.236/trunk@158797 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-06 14:37:56 +00:00
igor%mir2.org
2ae56359cc
Token.ZERO and Token.ONE are used only by interpreter and moved to Interpreter as corresponding icode constants.
...
git-svn-id: svn://10.0.0.236/trunk@158760 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-05 15:08:34 +00:00
igor%mir2.org
d53669a1db
Removal of no-longer applicable comments refering to SM code
...
git-svn-id: svn://10.0.0.236/trunk@158759 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-05 15:07:25 +00:00
igor%mir2.org
22dc09ca85
Removal of Token.DOT in NodeTransformer: it is always processed in IRFactory.
...
git-svn-id: svn://10.0.0.236/trunk@158758 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-05 15:06:18 +00:00
igor%mir2.org
2ad87465e5
When support for Context.FEATURE_MEMBER_EXPR_AS_FUNCTION_NAME is enables,
...
decompiler now does not turn them into assignment statements but keeps
original code with extension when printing function source. It allows for
better emulation of this JScript extension
git-svn-id: svn://10.0.0.236/trunk@158744 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-04 17:26:50 +00:00
igor%mir2.org
eef57c46db
Simplified handling of function expression statements: parser no longer
...
generate synthetic expression statement nodes for them.
git-svn-id: svn://10.0.0.236/trunk@158736 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-04 14:13:47 +00:00
igor%mir2.org
23e061f6e4
Normilizing numeration of Token constants after removal of few no longer used
...
constants in the previous patches
git-svn-id: svn://10.0.0.236/trunk@158735 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-04 14:12:01 +00:00
igor%mir2.org
4fa222560f
Splitting code generation in interpreter and class compiler into separated statement-only and expression only cases to add more checks.
...
git-svn-id: svn://10.0.0.236/trunk@158691 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-02 15:36:13 +00:00
igor%mir2.org
15cae6f909
Replacing generic Token.EXPRSTMT by Token.EXPR_VOID and Token.EXPR_RESULT and removal of Token.POP and Token.POPV. Now parser creates appropriate expression statements itself so there is no need to replace the time in NodeTransformer.
...
git-svn-id: svn://10.0.0.236/trunk@158687 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-02 13:11:06 +00:00
igor%mir2.org
49c95ac376
Fixing bug 249471:
...
Fixing parseFloat logic and Context usage cleanup.
I changed number start detection code in parseFloat to check properly for lone
+/- while making the code IMO more redable.
In addtion patch removes unused Context parameter from various functions in
NativeGlobal including parseFloat which was remainder from pre IdFunction
code.
git-svn-id: svn://10.0.0.236/trunk@158683 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-02 06:55:21 +00:00
igor%mir2.org
254fec20b1
Removal of Tiken.UNDEFINED: it was not used outside Interpreter
...
git-svn-id: svn://10.0.0.236/trunk@158647 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-01 16:40:44 +00:00
igor%mir2.org
9dc1b22550
Replacing state flags in TokenStream by separated boolean values to simplify
...
code and to remove flags that were set/cleared but never queried.
git-svn-id: svn://10.0.0.236/trunk@158642 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-01 14:52:22 +00:00
igor%mir2.org
9e58273527
Change IRFactory to return/accept Node, not Object as the type for parse tree
...
nodes. Parser already assumes in a few places that such Node and it is not
worth to pretend otherwise.
git-svn-id: svn://10.0.0.236/trunk@158641 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-01 10:39:28 +00:00
igor%mir2.org
be2eef23ca
Fixing JavaDoc: the previous changes removed Context(ContextFactory)
...
constructor as factory is associated automatically with Context but JavaDoc
continied to refer to this constructor form.
git-svn-id: svn://10.0.0.236/trunk@158606 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-30 15:28:04 +00:00
igor%mir2.org
4dae7d8134
Deprecation of ContextListener in favour of ContextFactory.Listener:
...
the later is stored in the factory and not in static variables.
For compatibility an instance of ContextFactory stored in static variables
is used to provide support for old Context.addContextListener etc. API.
The static instance of the factory is also used by Context.enter to create
Context instances providing simple way to customize Context: one just need
to initialize the global static factory.
git-svn-id: svn://10.0.0.236/trunk@158605 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-30 15:23:39 +00:00
igor%mir2.org
d9b5214238
Fix menu enable/disable misbehavior.
...
git-svn-id: svn://10.0.0.236/trunk@158601 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-30 13:29:41 +00:00
igor%mir2.org
dee3dab0cc
Fixing JDK 1.3 compatibility: TableModel.getRot() should not return null there.
...
git-svn-id: svn://10.0.0.236/trunk@158600 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-30 09:38:54 +00:00
igor%mir2.org
be0d9e0f58
Fixing scope problems with IdFunction when IdScriptable is top scope itself:
...
scope for IdFunction instances is determined through getTopScope,
not getParentScope() which can be null.
To prevent null scope initialization problems in future IdFunction constructor
now throws an exception if scope argument is null.
git-svn-id: svn://10.0.0.236/trunk@158578 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-29 15:43:01 +00:00
timeless%mozdev.org
27c47c4857
Bug 248458 Crash [@ nsJSIID::Equals] for null other
...
r=dbradley sr=shaver
git-svn-id: svn://10.0.0.236/trunk@158447 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-24 23:49:08 +00:00
brendan%mozilla.org
b3757f6391
NARCISSUS-only fix from Frierich Munch <colsebas@hotmail.com>.
...
git-svn-id: svn://10.0.0.236/trunk@158383 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-23 21:25:55 +00:00
bryner%brianryner.com
b9fee4bf3a
Make jsdouble hashing code strict-aliasing safe (bug 247877). r=brendan.
...
git-svn-id: svn://10.0.0.236/trunk@158258 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-21 17:57:10 +00:00