Function chakracore_sys::JsParse [] [src]

pub unsafe extern "system" fn JsParse(
    script: JsValueRef,
    sourceContext: JsSourceContext,
    sourceUrl: JsValueRef,
    parseAttributes: JsParseScriptAttributes,
    result: *mut JsValueRef
) -> JsErrorCode

Parses a script and returns a function representing the script. Requires an active script context. Script source can be either JavascriptString or JavascriptExternalArrayBuffer. In case it is an ExternalArrayBuffer, and the encoding of the buffer is Utf16, JsParseScriptAttributeArrayBufferIsUtf16Encoded is expected on parseAttributes. Use JavascriptExternalArrayBuffer with Utf8/ASCII script source for better performance and smaller memory footprint. The script to run. A cookie identifying the script that can be used by debuggable script contexts. The location the script came from. Attribute mask for parsing the script The result of the compiled script. The code JsNoError if the operation succeeded, a failure code otherwise.