Search completed in 0.86 seconds.
15 results for "js_free":
JS_freeop
MozillaProjectsSpiderMonkeyJSAPI referenceJS freeop
this article covers features introduced in spidermonkey 17 a wrapper for js_free.
... syntax void js_freeop(jsfreeop *fop, void *p); name type description fop jsfreeop * a pointer to jsfreeop structure to be used to get the implementation of free.
... description js_freeop is a wrapper for js_free(p) that may delay js_free(p) invocation as a performance optimization as specified by the given jsfreeop instance.
... see also mxr id search for js_freeop jsfreeop js_free bug 737365 ...
JS_FreezeObject
MozillaProjectsSpiderMonkeyJSAPI referenceJS FreezeObject
syntax bool js_freezeobject(jscontext *cx, js::handle<jsobject*> obj); name type description cx jscontext * the context.
... see also mxr id search for js_freezeobject javascript reference: the object.freeze method of object js_deepfreezeobject bug 492849 ...
JS_malloc
MozillaProjectsSpiderMonkeyJSAPI referenceJS malloc
syntax void * js_malloc(jscontext *cx, size_t nbytes); void * js_realloc(jscontext *cx, void *p, size_t oldbytes, size_t newbytes); char * js_strdup(jscontext *cx, const char *s); void js_free(jscontext *cx, void *p); name type description cx jscontext * pointer to a js context.
... p void * (js_realloc and js_free only) pointer to a previously allocated region of memory to resize or deallocate.
...when p is not null, js_realloc(cx, p, 0) behaves like js_free(cx, p) and returns null.
...And 4 more matches
Index
MozillaProjectsSpiderMonkeyIndex
275 js_freezeobject jsapi reference, reference, référence(2), spidermonkey freezes an object.
... 505 js_freeop jsapi reference, reference, référence(2), spidermonkey js_freeop is a wrapper for js_free(p) that may delay js_free(p) invocation as a performance optimization as specified by the given jsfreeop instance.
JSAPI reference
MozillaProjectsSpiderMonkeyJSAPI reference
these functions also allow spidermonkey to account the number of bytes allocated: js_malloc js_free js_realloc js_strdup struct jsfreeop added in spidermonkey 17 js_freeop added in spidermonkey 17 js_getdefaultfreeop added in spidermonkey 17 javascript objects, strings, and floating-point numbers are garbage collected.
...in jsapi 24 js_constructobject obsolete since jsapi 16 js_constructobjectwitharguments obsolete since jsapi 16 js_getclass js_getobjectprototype added in jsapi 17 js_getfunctionprototype added in spidermonkey 17 js_getarrayprototype added in spidermonkey 24 js_getconstructor js_getglobalforobject js_getinstanceprivate js_getprototype js_setprototype js_getprivate js_setprivate js_freezeobject added in spidermonkey 1.8.5 js_deepfreezeobject added in spidermonkey 1.8.5 js_isextensible added in spidermonkey 1.8.5 js_preventextensions added in spidermonkey 45 js_instanceof js_hasinstance js_isnative added in spidermonkey 17 js::toprimitiveadded in spidermonkey 45 js::newfunctionfromspecadded in spidermonkey 45 js_defaultvalueobsolete since jsapi 44 js_get_class obsole...
SpiderMonkey 1.8.5
MozillaProjectsSpiderMonkeyReleases1.8.5
applications must use js_getstringcharsandlength or js_encodestring/js_free and check for errors.
...isint32 js_encodestringtobuffer js_entercrosscompartmentcall js_evaluatescriptforprincipalsversion js_evaluateucscriptforprincipalsversion js_executeregexp js_executeregexpnostatics js_executescriptversion js_forget_string_flatness js_fileescapedstring js_finishjsonparse (removed in future releases, replaced with js_parsejson) js_flatstringequalsascii js_flattenstring js_flushcaches js_freezeobject js_getcompartmentprivate js_getemptystring js_getflatstringchars js_getgcparameter js_getgcparameterforthread js_getglobalforscopechain js_getinternedstringchars js_getinternedstringcharsandlength js_getownpropertydescriptor js_getpropertyattrsgetterandsetterbyid js_getpropertybyid js_getpropertybyiddefault js_getpropertydefault js_getpropertydescriptorbyid js_getruntimesec...
Choosing the right memory allocator
MozillaChoosing the right memory allocator
js_malloc() js_realloc() js_free() js_strdup() arena allocators nspr exposes arena allocators that can be used to efficiently allocate lots of small, uniformly sized objects.
JS::DeflateStringToUTF8Buffer
MozillaProjectsSpiderMonkeyJSAPI referenceJS::DeflateStringToUTF8Buffer
) return false; js::rooted<jsflatstring*> flatstr(cx, js_flattenstring(cx, str)); if (!flatstr) return false; size_t length = js::getdeflatedutf8stringlength(flatstr); char* buffer = static_cast<char*>(js_malloc(cx, length + 1)); if (!buffer) return false; js::deflatestringtoutf8buffer(flatstr, mozilla::rangedptr<char>(buffer, length)); buffer[length] = '\0'; printf("utf8: [%s]\n", buffer); js_free(cx, buffer); see also js::getdeflatedutf8stringlength bug 1034627 bug 1271014 -- added dstlenp and numcharsp ...
JSFreeOp
MozillaProjectsSpiderMonkeyJSAPI referenceJSFreeOp
see also mxr id search for jsfreeop js_freeop js_getdefaultfreeop jsfinalizecallback jsdestroycompartmentcallback bug 737365 ...
JS_DeepFreezeObject
MozillaProjectsSpiderMonkeyJSAPI referenceJS DeepFreezeObject
see also mxr id search for js_deepfreezeobject js_freezeobject bug 492849 ...
JS_EncodeCharacters
MozillaProjectsSpiderMonkeyJSAPI referenceJS EncodeCharacters
*/ js_free(cx, dst); return js_true; on success, js_encodecharacters sets *dstlenp to the real result length and returns js_true.
JS_GetDefaultFreeOp
MozillaProjectsSpiderMonkeyJSAPI referenceJS GetDefaultFreeOp
see also mxr id search for js_getdefaultfreeop js_freeop jsfreeop bug 737365 ...
JS_SealObject
MozillaProjectsSpiderMonkeyJSAPI referenceJS SealObject
js_freezeobject and js_deepfreezeobject are near-substitutes compatible with ecmascript semantics, implementing semantics compatible with those of object.freeze.
SpiderMonkey 1.8.7
MozillaProjectsSpiderMonkeyReleases1.8.7
isint32 js_encodestringtobuffer js_entercrosscompartmentcall js_evaluatescriptforprincipalsversion js_evaluateucscriptforprincipalsversion js_executeregexp js_executeregexpnostatics js_executescriptversion js_forget_string_flatness js_fileescapedstring js_finishjsonparse (removed in future releases, replaced with js_parsejson) js_flatstringequalsascii js_flattenstring js_flushcaches js_freezeobject js_getcompartmentprivate js_getemptystring js_getflatstringchars js_getgcparameter js_getgcparameterforthread js_getglobalforscopechain js_getinternedstringchars js_getinternedstringcharsandlength js_getownpropertydescriptor js_getpropertyattrsgetterandsetterbyid js_getpropertybyid js_getpropertybyiddefault js_getpropertydefault js_getpropertydescriptorbyid js_getruntimesec...
SpiderMonkey 1.8
MozillaProjectsSpiderMonkeyReleases1.8
js_encodestring is a new variation on js_getstringbytes that returns a newly allocated, writable buffer which the application must js_free.