]> git.saurik.com Git - cycript.git/blobdiff - JavaScript.hpp
Work around libclang to find parameterized macros.
[cycript.git] / JavaScript.hpp
index 87689b589d5321a897a64de8bedaf1360a679da6..33b3db8bd674ce22716f6b90e05eb1ce4e027b75 100644 (file)
@@ -103,11 +103,11 @@ JSObjectRef CYCastJSObject(JSContextRef context, JSValueRef value);
 JSValueRef CYJSUndefined(JSContextRef context);
 JSValueRef CYJSNull(JSContextRef context);
 
-void *CYCastPointer_(JSContextRef context, JSValueRef value);
+void *CYCastPointer_(JSContextRef context, JSValueRef value, bool *guess = NULL);
 
 template <typename Type_>
-_finline Type_ CYCastPointer(JSContextRef context, JSValueRef value) {
-    return reinterpret_cast<Type_>(CYCastPointer_(context, value));
+_finline Type_ CYCastPointer(JSContextRef context, JSValueRef value, bool *guess = NULL) {
+    return reinterpret_cast<Type_>(CYCastPointer_(context, value, guess));
 }
 
 void CYPoolFFI(CYPool *pool, JSContextRef context, sig::Type *type, ffi_type *ffi, void *data, JSValueRef value);
@@ -143,6 +143,7 @@ struct CYRegisterHook {
 
 JSObjectRef CYMakePointer(JSContextRef context, void *pointer, size_t length, sig::Type *type, ffi_type *ffi, JSObjectRef owner);
 
+JSObjectRef CYMakeType(JSContextRef context, const char *encoding);
 JSObjectRef CYMakeType(JSContextRef context, sig::Type *type);
 JSObjectRef CYMakeType(JSContextRef context, sig::Signature *signature);