File tree 5 files changed +11
-9
lines changed
5 files changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ function test(file) {
19
19
20
20
// should export memory
21
21
assert ( exports . memory instanceof WebAssembly . Memory ) ;
22
- assert ( typeof exports . memory . copy === "function" ) ;
22
+ assert ( typeof exports . memory . compare === "function" ) ;
23
23
24
24
// should be able to get an exported string
25
25
assert . strictEqual ( exports . __getString ( exports . COLOR ) , "red" ) ;
Original file line number Diff line number Diff line change @@ -713,13 +713,15 @@ export class Compiler extends DiagnosticEmitter {
713
713
}
714
714
case ElementKind . FUNCTION : {
715
715
let functionInstance = < Function > element ;
716
- let signature = functionInstance . signature ;
717
- if ( signature . requiredParameters < signature . parameterTypes . length ) {
718
- // utilize trampoline to fill in omitted arguments
719
- functionInstance = this . ensureTrampoline ( functionInstance ) ;
720
- this . ensureBuiltinArgumentsLength ( ) ;
716
+ if ( ! functionInstance . hasDecorator ( DecoratorFlags . BUILTIN ) ) {
717
+ let signature = functionInstance . signature ;
718
+ if ( signature . requiredParameters < signature . parameterTypes . length ) {
719
+ // utilize trampoline to fill in omitted arguments
720
+ functionInstance = this . ensureTrampoline ( functionInstance ) ;
721
+ this . ensureBuiltinArgumentsLength ( ) ;
722
+ }
723
+ if ( functionInstance . is ( CommonFlags . COMPILED ) ) this . module . addFunctionExport ( functionInstance . internalName , prefix + name ) ;
721
724
}
722
- if ( functionInstance . is ( CommonFlags . COMPILED ) ) this . module . addFunctionExport ( functionInstance . internalName , prefix + name ) ;
723
725
break ;
724
726
}
725
727
case ElementKind . PROPERTY : {
Original file line number Diff line number Diff line change @@ -290,8 +290,8 @@ export abstract class DiagnosticEmitter {
290
290
if ( range ) message = message . withRange ( range ) ;
291
291
if ( relatedRange ) message . relatedRange = relatedRange ;
292
292
this . diagnostics . push ( message ) ;
293
- // console.log(formatDiagnosticMessage(message, true, true) + "\n"); // temporary
294
- // console.log(<string>new Error("stack").stack);
293
+ console . log ( formatDiagnosticMessage ( message , true , true ) + "\n" ) ; // temporary
294
+ console . log ( < string > new Error ( "stack" ) . stack ) ;
295
295
}
296
296
297
297
/** Emits an overly pedantic diagnostic message. */
You can’t perform that action at this time.
0 commit comments