Commit Graph

683 Commits

Author SHA1 Message Date
waldemar%netscape.com
fec02531da Updated to generate Netscape 6-compatible HTML 2000-08-11 06:27:55 +00:00
waldemar%netscape.com
7a3bd65ac3 Added attributes to for-initializers and no-line-breaks in a few places 2000-08-11 06:27:25 +00:00
waldemar%netscape.com
d955e75027 Updated to match documentation site 2000-08-11 06:24:57 +00:00
waldemar%netscape.com
b7c2380049 Updated to match styles.css on documentation site 2000-08-11 06:24:39 +00:00
rogerl%netscape.com
e8f1a9e20c Added 'static' to global object routines. 2000-08-04 20:54:24 +00:00
rogerl%netscape.com
67730faf1f Oops. Left icode output on by default, now off. 2000-08-04 20:37:42 +00:00
rogerl%netscape.com
0013224436 Prototype munging for built-in global properties, implemented Function
object & Boolean object.
2000-08-04 20:28:35 +00:00
waldemar%netscape.com
9e38333da6 Made link order consistent 2000-08-02 23:09:53 +00:00
waldemar%netscape.com
8941a10acb Fixed Mac errors and warnings 2000-08-02 23:09:29 +00:00
beard%netscape.com
e2d1e94396 fixing warnings, removing need for JStrings to be copied for mClass 2000-08-02 03:53:04 +00:00
rginda%netscape.com
80b337ffd6 shut up "unused param" warnings by only naming the register param if the icode uses a RegisterList operand. 2000-07-29 02:00:12 +00:00
rogerl%netscape.com
9cb37bc8c8 Function prototype objects etc. 2000-07-26 01:56:47 +00:00
rogerl%netscape.com
c30779b359 More ECMA 3 mucking about to support constructors etc. 2000-07-25 22:58:04 +00:00
beard%netscape.com
583d45e258 added jsmath.cpp/h 2000-07-21 05:07:29 +00:00
beard%netscape.com
90c948a47a XML project file. 2000-07-21 05:07:05 +00:00
beard%netscape.com
eec51fa4ce update dependencies to include jsmath.o 2000-07-21 05:01:10 +00:00
beard%netscape.com
94888cdb78 add jsmath.cpp to the build. 2000-07-21 05:00:43 +00:00
beard%netscape.com
b955eb7e09 scope of loop variables fix 2000-07-21 05:00:10 +00:00
rogerl%netscape.com
84455b51d9 Implementing Object.prototype object and global object for ECMA 3
Adding Math class support.
2000-07-21 01:16:49 +00:00
rogerl%netscape.com
06f0a5261f Removed all xxxCall, using simple call for everything.
Changed methods to use mMethods vector instead.
Various other fixes etc.
2000-07-18 20:53:03 +00:00
beard%netscape.com
a5ef09a1a6 cleaned up by removing widenCString() calls when using world.identifiers 2000-07-17 20:39:19 +00:00
rginda%netscape.com
950d90e264 removing bogus assert (per rogerl) 2000-07-15 00:01:25 +00:00
beard%netscape.com
96e8363f86 added operator[](const char*) to StringAtomTable. 2000-07-14 23:10:02 +00:00
rogerl%netscape.com
3def89ee0d Fixed slots for non-function vars, plus bug in slot xcrement. 2000-07-14 22:23:20 +00:00
rogerl%netscape.com
0d866e25b5 Backed out time() 2000-07-14 01:46:14 +00:00
rogerl%netscape.com
23e9d7c1c8 Type targetted binary operators.
Added 'time()' function as native.
2000-07-14 01:00:53 +00:00
beard%netscape.com
89608ef140 need <stdio.h> for fopen on the Mac. 2000-07-13 02:23:55 +00:00
beard%netscape.com
60feb5d1fd fixing readEvalFile to save off important Context data members. implemented identical_Default for string 2000-07-13 01:35:57 +00:00
beard%netscape.com
e9a25e0a62 fixing readEvalFile() by creating another Context 2000-07-13 00:44:30 +00:00
rogerl%netscape.com
58dc7e47b7 Switching to generic binary operator in order to distinguish situation
where Operators package had been loaded and be able to generate typed
versions of the binary operators otherwise.
2000-07-13 00:14:54 +00:00
rogerl%netscape.com
b8bd1adb30 Implemented Import -only it's not in the parser yet.
Added missing defineXXX functions.
2000-07-11 23:49:20 +00:00
rginda%netscape.com
3a02396fda cleaned up linux warnings, minor debugger tweaks 2000-07-11 23:08:03 +00:00
rogerl%netscape.com
774d010635 More on @ operator. Fixed R 4billion print bug. 2000-07-11 20:54:06 +00:00
rogerl%netscape.com
087d2475a7 Some parts of x@<name> working. 2000-07-10 23:18:07 +00:00
rogerl%netscape.com
daba9186aa Support for 'constructor'. 2000-07-08 01:08:29 +00:00
rogerl%netscape.com
1375151969 Removed preprocess step, consolidated identifier handling. 2000-07-06 18:26:26 +00:00
beard%netscape.com
0eeae607ae Fix build bustage. 2000-06-29 18:40:58 +00:00
rogerl%netscape.com
fd98adafce use handleDot for call, too. 2000-06-29 18:30:47 +00:00
beard%netscape.com
8f5fea173e delete property support. 2000-06-29 18:14:14 +00:00
beard%netscape.com
a4c5f704f4 DELETE_PROP 2000-06-29 18:13:46 +00:00
beard%netscape.com
7a6367c583 DELETE_PROP 2000-06-29 17:14:56 +00:00
beard%netscape.com
11134b4173 added DELETE_PROP instruction to implement the "delete" operation. 2000-06-29 17:11:50 +00:00
beard%netscape.com
97dfdc5f04 unused parameter warning 2000-06-29 05:48:09 +00:00
beard%netscape.com
8f4cadb250 complementary operator delete(void*, JSClass*). 2000-06-29 05:46:36 +00:00
beard%netscape.com
8891b0c7ba some classes to test js2 with. 2000-06-29 04:49:48 +00:00
beard%netscape.com
8da0055bc5 updated dependencies 2000-06-29 04:25:10 +00:00
beard%netscape.com
074f981eb4 Changed StaticCall to use static slot. 2000-06-29 04:23:56 +00:00
beard%netscape.com
b202adfd39 Fixing static dotted expressions. 2000-06-29 04:23:20 +00:00
beard%netscape.com
7a512866fd now uses conditional compilation #if defined(OPCODE_NAMES), so that a simple "icode.h" can be included by vmtypes.h and vmtypes.cpp. 2000-06-29 04:21:00 +00:00
beard%netscape.com
486b437613 moved all machine generated classes, etc. to icode.h. 2000-06-29 04:19:19 +00:00
beard%netscape.com
2a451cdd8b Generated by tools/gencode.pl. 2000-06-29 04:18:16 +00:00
beard%netscape.com
640ba6e24c fixed static calls. 2000-06-29 03:15:52 +00:00
rogerl%netscape.com
63744d7c1c Implicit this and class lookup stuff. 2000-06-29 01:21:41 +00:00
beard%netscape.com
237dd352ed implemented JSClass::printProperties(). 2000-06-28 19:46:13 +00:00
beard%netscape.com
9930edd0d5 Enhanced printing of types. 2000-06-28 19:45:44 +00:00
beard%netscape.com
c0e9f6d274 Type of a JSType* is Type_Type (wow, recursive). Changed mBaseType to be JSType* instead of const JSType*. 2000-06-28 19:45:09 +00:00
rogerl%netscape.com
52bffdadcf First set of unified 'dot' handling changes for statics. 2000-06-28 18:41:30 +00:00
beard%netscape.com
d40b8dd8cb added jsclasses.h 2000-06-28 18:10:04 +00:00
beard%netscape.com
941b505765 Fix string <. 2000-06-28 16:38:20 +00:00
beard%netscape.com
d9bf640477 Fixed dynamic lookup of static slots. Added code to compare strings. 2000-06-28 16:32:52 +00:00
beard%netscape.com
b1350d87b6 GET_STATIC/SET_STATIC/STATIC_XCR now use an index rather than a name. Implemented GET_PROP/SET_PROP for class objects (looks up slot dynamically, etc.) 2000-06-28 16:15:06 +00:00
beard%netscape.com
866b5d3d8d GET_STATIC/SET_STATIC/STATIC_XCR now use an index rather than a name. Now using JSClass::hasStatic() rather than looking up statics in class' scope. 2000-06-28 16:14:18 +00:00
beard%netscape.com
8132734212 GET_STATIC/SET_STATIC/STATIC_XCR now use an index rather than a name. 2000-06-28 16:13:12 +00:00
beard%netscape.com
970477555f Static slots. 2000-06-28 16:11:54 +00:00
beard%netscape.com
2b1351cc3b Win-specific operator== noise. 2000-06-27 03:52:56 +00:00
beard%netscape.com
4873ce7882 Fixed unitialized static class members. 2000-06-27 03:43:40 +00:00
beard%netscape.com
7b2b4a1e2f addSlot -> defineSlot, added defineStatic. 2000-06-27 03:42:42 +00:00
beard%netscape.com
74e8d0a780 Fixed type management. 2000-06-27 03:21:33 +00:00
rogerl%netscape.com
fbdb3fe1c1 lots of stuff me and Patrick did 2000-06-27 02:39:32 +00:00
beard%netscape.com
965f10e915 JSValue::operator==: added CASE(type) to fix warning. 2000-06-26 17:47:07 +00:00
beard%netscape.com
f276cc3dfd added JSObject::deleteProperty(), and changed mName in JSType to be a JSString. Need to revisit other uses of String soon. 2000-06-26 17:42:20 +00:00
beard%netscape.com
07dff8c5d1 simplified string addition 2000-06-26 17:25:25 +00:00
beard%netscape.com
fef138fae2 defined JSStringBase, and constructors from in JSString 2000-06-26 17:24:57 +00:00
beard%netscape.com
769d11bcbf String addition: don't share structure with LHS. 2000-06-26 17:09:27 +00:00
beard%netscape.com
45301bb589 added constructor from JSString&. 2000-06-26 16:55:01 +00:00
beard%netscape.com
3a78e14938 Reset register usage after generating each initializer statement. 2000-06-26 15:19:45 +00:00
beard%netscape.com
714e109074 Simplified NEW_CLASS, using a single do .. while loop, introducing nextPC instruction iterator to simplify initial case. now calls all defined constructors. 2000-06-26 15:06:36 +00:00
beard%netscape.com
07d6ee2613 Only call non-null constructors. 2000-06-25 17:04:38 +00:00
beard%netscape.com
40e53d46ea Conditionally set constructor, if it has any instructions. 2000-06-25 17:04:01 +00:00
beard%netscape.com
21f549896a updated dependencies 2000-06-25 16:44:29 +00:00
beard%netscape.com
d6c6cc31bb check for non-null superClass 2000-06-25 16:43:25 +00:00
beard%netscape.com
5d311184e2 hooked up superClass' scope as the prototype of a class's scope, to do method inheritance, removed bogus JSInstance::getSlotCount(), which overcounted slots. 2000-06-25 16:35:33 +00:00
beard%netscape.com
728580c6f8 Added calls to superClass constructors. 2000-06-24 22:42:43 +00:00
beard%netscape.com
e41bd745dd JSInstance::getSlotCount() no longer recursive. 2000-06-24 22:42:15 +00:00
beard%netscape.com
7b76b9503a Beginning support for superclass slots. 2000-06-24 22:07:00 +00:00
beard%netscape.com
36eef7adea Added emptyArgs, removed unused return value in readEvalFile 2000-06-24 05:42:51 +00:00
beard%netscape.com
a6493add9f enable RTTI 2000-06-24 05:36:52 +00:00
beard%netscape.com
b877fde64f VC++ doesn't like local classes in templates. 2000-06-24 05:36:09 +00:00
beard%netscape.com
c5298ced1d major surgery to enable the "load()" native function. 2000-06-24 05:25:33 +00:00
beard%netscape.com
46c0a7c5a8 Experiment with looking up methods in the prototype chain. 2000-06-24 05:22:23 +00:00
beard%netscape.com
c337fff76a Always use the target object, regardless of where a method property is found along the prototype chain. 2000-06-24 05:21:49 +00:00
beard%netscape.com
8558f071a4 When generating a reference to "this" use the current code generator's mClass when appropriate. 2000-06-24 05:21:03 +00:00
rginda%netscape.com
486d1cc51a fixing source stepping (opcode stepping to come back later)
debugger is now quiet by default.
2000-06-24 02:53:29 +00:00
beard%netscape.com
27b088f22a Removed JSType::isClassType(). 2000-06-24 02:51:34 +00:00
beard%netscape.com
565b0389db Added JSClass::get/setConstructor(). 2000-06-24 02:51:03 +00:00
beard%netscape.com
9fd0505086 Added call to constructor when executing NEW_CLASS. 2000-06-24 02:50:23 +00:00
beard%netscape.com
47638a00c7 Generating default constructor to run slot initializers. 2000-06-24 02:49:45 +00:00
beard%netscape.com
146e187c7b testCompile() is static 2000-06-24 01:04:58 +00:00
rogerl%netscape.com
e497a7809f typing 'this' 2000-06-24 01:02:34 +00:00
rogerl%netscape.com
432c8b3cdc Got newClass working, added printProperties for instances, some slot
stuff is happening.
2000-06-24 00:50:59 +00:00
beard%netscape.com
f304229d7f added NEW_CLASS instruction, to instantiate classes. 2000-06-23 23:49:48 +00:00
beard%netscape.com
35b239cd47 added NEW_CLASS instruction. 2000-06-23 23:49:17 +00:00
rogerl%netscape.com
e939fbddc4 Adding slot handling to code gen. 2000-06-23 23:43:24 +00:00
beard%netscape.com
841b79b5eb added NEW_CLASS instruction. 2000-06-23 23:41:27 +00:00
beard%netscape.com
da108e7b96 Added JSClass::hasSlot, getSlotCount(), and JSInstance. 2000-06-23 23:25:55 +00:00
beard%netscape.com
9f413f408b JSValue::type now JSType* instead of const JSType*, all predefined JSType objects no longer const as well. 2000-06-23 23:25:14 +00:00
rogerl%netscape.com
89515e83dc Removed FUNCTION instruction, other class related junk. 2000-06-23 22:53:09 +00:00
rginda%netscape.com
da45d9b0eb Added debugger opcode, change InstructionMap to a std::map, print source lines while tracing 2000-06-23 22:27:17 +00:00
rogerl%netscape.com
ea920b48c8 Add return statement if the function doesn't end with one 2000-06-23 21:20:03 +00:00
beard%netscape.com
da19218b3e added assertion to ensure that mPC is always valid before fetching the next instruction. 2000-06-23 06:10:14 +00:00
beard%netscape.com
95adc8b187 Additional JSClass processing: defining slots, generating methods. 2000-06-23 05:13:04 +00:00
beard%netscape.com
ca9001f387 When using a JSScope that has a parent scope, don't bother defining the standard properties, they will be shared. 2000-06-23 05:10:46 +00:00
beard%netscape.com
6ccb94e600 A JSClass is a JSType now, and has a JSScope. Added addSlot, getSlot, getScope. 2000-06-23 05:09:37 +00:00
beard%netscape.com
dee62b8d67 remove unused file. 2000-06-23 04:10:04 +00:00
beard%netscape.com
f7c44fcf6f putting the JSClass* in the current global scope, and looking up superclass rereferences. 2000-06-23 02:22:55 +00:00
rogerl%netscape.com
33c9eb064a Added support for 'debugger' as a statement. (Rob made me) 2000-06-23 00:08:10 +00:00
beard%netscape.com
5ee7d6da77 JSClass support. 2000-06-21 23:58:17 +00:00
beard%netscape.com
124280ce07 initial checkin, starting on a representation for JS2 classes. 2000-06-21 23:57:09 +00:00
rogerl%netscape.com
f2591282dc Work to support 'this'. 2000-06-21 22:32:21 +00:00
rogerl%netscape.com
27e254fee3 Changed use of Register to TypedRegister throughout. 2000-06-20 22:45:45 +00:00
rogerl%netscape.com
8a71a568af Support for TypedRegister 2000-06-20 22:44:46 +00:00
rogerl%netscape.com
a8a18e9d21 Added tests for scripts as strings. 2000-06-16 01:37:47 +00:00
rogerl%netscape.com
ecd0d99e85 Mucking about with operator overlaoding plus initializing global context
- beginning type stuff.
2000-06-16 01:36:59 +00:00
rogerl%netscape.com
670a8310fb Fixed spelling. 2000-06-16 01:35:25 +00:00
rogerl%netscape.com
b2f3dff014 Added op= support. 2000-06-15 16:03:54 +00:00
rogerl%netscape.com
c354e43376 Mark top-level execution as 'script' rather than function - to handle
vars correctly.
2000-06-14 23:28:38 +00:00
rogerl%netscape.com
5762b34619 Added 'Function' instruction, plus suppresses class output if there is
no super specified. (ok it's a hack, but it works)
2000-06-14 23:27:28 +00:00
rogerl%netscape.com
6526fedd31 Adding support for Functions and Vars, preXcrement, object literals. 2000-06-14 23:26:15 +00:00
waldemar%netscape.com
2166c80bec Added parsing and printing of classes, interfaces, and namespaces 2000-06-02 04:35:44 +00:00
waldemar%netscape.com
767f3c1669 Widened default line width to 30 2000-06-01 03:31:17 +00:00
waldemar%netscape.com
5c440a5bc5 Added function and constructor parsing and printing; fixed printing of blocks, compound statements, and :: 2000-06-01 03:30:58 +00:00
waldemar%netscape.com
ebbccfd9f8 Added two-argument linearBreak 2000-06-01 03:30:19 +00:00
rogerl%netscape.com
4e3dcc082c Removed old branches, changed offset printing to handle NULL operand. 2000-05-26 22:35:36 +00:00
rogerl%netscape.com
565b842243 Update to new icg constructor etc. 2000-05-26 22:34:42 +00:00
rogerl%netscape.com
573531b249 Statement fun 2000-05-26 22:33:05 +00:00
waldemar%netscape.com
bd3b79569c Added var, const, and for statements 2000-05-26 06:20:11 +00:00
waldemar%netscape.com
cec8a6816d Fixed case/default indenting 2000-05-24 02:18:57 +00:00
rogerl%netscape.com
39ebb9c8d8 Codegen for statements. Blew off old statement API and most of the test
functions for now, sorry.
2000-05-24 02:11:39 +00:00
waldemar%netscape.com
d4e4f10d14 Turned on statement parsing and printing 2000-05-24 01:51:32 +00:00
waldemar%netscape.com
c970639ae9 Added statement parsing 2000-05-24 01:51:20 +00:00
waldemar%netscape.com
fe6fac7c85 Added using std::fmod declaration 2000-05-24 00:55:23 +00:00
waldemar%netscape.com
389625522b Fixed Mac warning 2000-05-24 00:54:56 +00:00
waldemar%netscape.com
bdd3276507 Fixed Mac warnings 2000-05-24 00:54:40 +00:00
waldemar%netscape.com
0765893319 Fixed syntax errors: can't use qualified names in class definitions, and 'not' is a C++ reserved word 2000-05-24 00:54:28 +00:00
rginda%netscape.com
b71c85c7dc apparently windows is too 2000-05-23 00:15:06 +00:00
rginda%netscape.com
27345b3bb3 linux is so picky 2000-05-23 00:13:48 +00:00
rogerl%netscape.com
709d6c75d9 COMPARE_GT etc are gone. 2000-05-23 00:09:44 +00:00
rogerl%netscape.com
8dc4133f96 Fall out from operator overloading. 2000-05-23 00:09:02 +00:00
rogerl%netscape.com
932d63213b Added operator overloading support 2000-05-23 00:08:29 +00:00
rginda%netscape.com
6fa16759c6 quieting linux warnings and fixing build bustage 2000-05-22 21:05:35 +00:00