JavaScript : Object System

Seems to be the toughest part of the project, providing inbuilt object's support. Thanks to the specification provided by Ecmascript, finally got hold of whole Object thing. Time to speed up my work now..

JavaScript's object system is based around a global Object which is created before the control enters any execution context and that is its whole purpose also. We can't call it as a function neither as a constructor. All the other features are its properties only.

It defines some built in values like NaN( not a number) , Infinity ( infinitely large number) and undefined .
Contains eval(), parseInt() etc as function properties.
The most important properties are the Constructor properties
It contains all the built in constructors used in JavaScript.

Object(), Function(), Array(), String(), Boolean(), Number(), Regexp(), Error() etc. they perform different depending on use like as a function and as constructor.

the frequently used Math and JSON object is also the property of Global Object.

JavaScript possess a slightly complex object system due to nature of "prototype". I have tried to explain this object system here :JavaScript: Objects
I'm working on implementing this Object System in PIR using pmc subclass and modifying them to suit JavaScript's needs.
Will post an another detailed post on implemention this week.