Last active
November 10, 2016 02:36
-
-
Save ptomato/8d08327a278b0ac331cb41788acc94d9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "jsapi.h" | |
int main(int argc, const char *argv[]) | |
{ | |
JS_Init(); | |
JSRuntime *rt = JS_NewRuntime(8L * 1024 * 1024, JS_USE_HELPER_THREADS); | |
if (!rt) | |
return 1; | |
JSContext *cx = JS_NewContext(rt, 8192); | |
if (!cx) | |
return 1; | |
{ | |
JSAutoRequest ar(cx); | |
JS::CompileOptions options(cx); | |
} | |
JS_DestroyContext(cx); | |
JS_DestroyRuntime(rt); | |
JS_ShutDown(); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment