In last month's Dr. Scripter, we discussed weak referencing, a significant feature of the newly released ScriptEase ISDK 4.30d. However, there are other noteworthy
improvements found in this latest release, which we highlight below.
Create
Wrappers Automatically
4.30d includes the wrapper.jse script (located in the tools folder), which reads C header files and create SE:ISDK/C wrappers automatically. For
example, with this header file:
Wrapper.jse would create a .c file with the functions, tables, and initializers to call these two function from within a script.We intend to add improvements to wrapper.jse and so we look forward to feedback on what should be added.
Optionally Force ECMAScript-Compliant
Object Definition
ScriptEase has traditionally allowed objects to be defined
automatically, just by referencing a member. For example,this script:
would automatically make "foo" be an instance of an Object. While
flexible and desirable under certain circumstances, this behavior does not conform to the more rigid ECMAScript specification. Therefore, with "#define JSE_AUTO_OBJECT 0" in your jseopt.h
file you can now disable this behavior, so that the above script would generate an error and instead would have to be written as:
Faster Auto-Increment And Auto-Decrement Version 4.30d improves how the virtual machine handles increment (++) and decrement (--). They now execute noticeably faster and handle prototypes of the global. New Radix Option for Number.prototype.toString() The ECMAScript specification is unclear about how the radix operation is to be handled with number.toString(radix); previous
releases of SE:ISDK/C have ignored that parameter. With the 4.30d release radix will be used as most script-writers expect, so that the following script will create the string "19 13 10011":
The radix options can be enabled by adding #define JSE_NUMBER_TOSTRINGWITHRADIX 1 in your jseopt.h file Have a question about how to use ScriptEase:ISDK? Let Dr. Scripter know at http://support.nombasxxx.com/. |