JavaScript-1.5 Reference

JS_DestroyScript Function

Summary

Frees a compiled script when no longer needed.

Syntax

void) JS_DestroyScript(JSContext *cx, JSScript *script);
NameTypeDescription
cxJSContext *Pointer to a JS context from which to derive runtime information.
scriptJSScript *Compiled script to destroy.

Description

JS_DestroyScript destroys the compiled script object, script, thereby freeing the space allocated to it for other purposes. Generally, after you compile a script you do not want to call JS_DestroyScript until you no longer need to use the script. Othewise you will have to recompile the script to use it again.

See Also

Groups [ Function ]
Documents [ LXR ID Search ]
Entries [ JS_CompileFile | JS_CompileScript | JS_DecompileScript | JS_EvaluateScript | JS_ExecuteScript ]

This page was generated by APIDOC