bang590 / JSPatch

JSPatch bridge Objective-C and Javascript using the Objective-C runtime. You can call any Objective-C class and method in JavaScript by just including a small engine. JSPatch is generally used to hotfix iOS App.
MIT License
11.37k stars 2.24k forks source link

JPCFunction c函数返回值 #802

Open momoAI opened 7 years ago

momoAI commented 7 years ago

require('JPEngine').addExtensions(['JPCFunction']) defineCFunction("NSHomeDirectory", "NSString *, void") defineClass("Test", { tableView_didSelectRowAtIndexPath: function(tableView, indexPath) { var path = NSHomeDirectory(); console.log("=======" + path); } }, {});

调用NSHomeDirectory()返回值为false是怎么回事