Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

ixion::javascript Namespace Reference


Compounds

class  ixion::javascript::interpreter
class  ixion::javascript::js_array
class  ixion::javascript::list_scope
class  ixion::javascript::value_with_methods::bound_method
struct  ixion::javascript::context
class  ixion::javascript::value
class  ixion::javascript::value_with_methods

Functions

ref< valuemakeUndefined ()
ref< valuemakeNull ()
ref< valuemakeValue (signed long val)
ref< valuemakeConstant (signed long val)
ref< valuemakeValue (signed int val)
ref< valuemakeConstant (signed int val)
ref< valuemakeValue (unsigned long val)
ref< valuemakeConstant (unsigned long val)
ref< valuemakeValue (unsigned int val)
ref< valuemakeConstant (unsigned int val)
ref< valuemakeValue (double val)
ref< valuemakeConstant (double val)
ref< valuemakeValue (std::string const &val)
ref< valuemakeConstant (std::string const &val)
ref< valuemakeArray (TSize size=0)
ref< valuemakeLValue (ref< value > target)
ref< valuewrapConstant (ref< value > val)
void addGlobal (interpreter &ip)
void addMath (interpreter &ip)
void addStandardLibrary (interpreter &ip)


Detailed Description

This code tries to be an implementation of ECMAScript 4, as available at http://www.mozilla.org/js/language/ Note that ES4 is still in the process of standardization.

It is meant to behave like an ES4 interpreter in strict mode, none of the backward-compatible braindead-isms like newline semicolon insertion and other stuff will ever be implemented.

This is the list of its shortcomings:

Be advised that a javascript value that is passed to you through the interpreter, e.g. as a call parameter, may not be of the type that you expect. For example, in "var x = 4; f(x);", what comes in as the parameter x into f is a wrapper value that adds assign()ability to a value that is wrapped inside. The advised solution to get the object that you expect is to call eliminateWrappers() on the potentially wrapped value.


Function Documentation

void addGlobal interpreter   ip
 

void addMath interpreter   ip
 

void addStandardLibrary interpreter   ip
 

ref<value> makeArray TSize    size = 0
 

ref<value> makeConstant std::string const &    val
 

ref<value> makeConstant double    val
 

ref<value> makeConstant unsigned int    val
 

ref<value> makeConstant unsigned long    val
 

ref<value> makeConstant signed int    val
 

ref<value> makeConstant signed long    val
 

ref<value> makeLValue ref< value   target
 

ref<value> makeNull  
 

ref<value> makeUndefined  
 

ref<value> makeValue std::string const &    val
 

ref<value> makeValue double    val
 

ref<value> makeValue unsigned int    val
 

ref<value> makeValue unsigned long    val
 

ref<value> makeValue signed int    val
 

ref<value> makeValue signed long    val
 

ref<value> wrapConstant ref< value   val
 


Generated on Wed Oct 31 17:12:27 2001 for ixlib by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001