Export function table by default and add an option to import it

This commit is contained in:
dcodeIO
2018-03-23 15:12:03 +01:00
parent 2738eee9cd
commit ec5bb7ad51
12 changed files with 27 additions and 4 deletions

View File

@ -360,6 +360,7 @@ exports.main = function main(argv, options, callback) {
assemblyscript.setNoAssert(compilerOptions, !!args.noAssert);
assemblyscript.setNoMemory(compilerOptions, !!args.noMemory);
assemblyscript.setImportMemory(compilerOptions, !!args.importMemory);
assemblyscript.setImportTable(compilerOptions, !!args.importTable);
assemblyscript.setMemoryBase(compilerOptions, args.memoryBase >>> 0);
assemblyscript.setSourceMap(compilerOptions, args.sourceMap != null);

View File

@ -107,6 +107,10 @@
"desc": "Sets the start offset of compiler-generated static memory.",
"type": "number"
},
"importTable": {
"desc": "Imports the function table instance provided by the embedder.",
"type": "boolean"
},
"noLib": {
"desc": "Does not include the shipped standard library.",
"type": "boolean"