Implementation-supplied code (Definition)

Script source that is provided by the implementation.

Availability:

ECMAScript edition - 2

The implementation-supplied code is provided by the hosting environment when it creates an implementation defined function.

As the function is created, the hosting environment may or may not additionally provide a formal parameter list for the function.

On initialization, the scope chain is set up to contain the activation object as its first element.

The caller provides this value, but in some situations the value null may be passed. In that case, the global object will be used in its place.

The ImplicitThis and ImplicitParents attributes affect the way that other lists of objects are attached to the scope chain. They interact to some extent as illustrated in this table:

ImplicitThisImplicitParentsFirst itemSecond itemThird itemFourth item
nonoactivation objectglobal object--
noyesactivation objectlist of objects provided by this valueglobal object-
yesnoactivation objectthis valueglobal object-
yesyesactivation objectthis valuelist of objects provided by this valueglobal object

Finally the Global object is placed in the scope chain after all other objects.

Variable instantiation is performed using the activation object as the variable object and any initial variables are flagged with a DontDelete attribute.

See also:Executable code, Execution context, Implementation-defined behavior

Cross-references:

ECMA 262 edition 2 - section - 10.1.1

ECMA 262 edition 2 - section - 10.1.2

ECMA 262 edition 2 - section - 10.1.6

ECMA 262 edition 2 - section - 10.2.4

ECMA 262 edition 3 - section - 10.1.1

ECMA 262 edition 3 - section - 10.1.2

ECMA 262 edition 3 - section - 10.1.6