Skip to content

Commit 28f1d0d

Browse files
committed
go even shorter in case that helps the browsers inline
1 parent 9560377 commit 28f1d0d

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/compiler/jsexecute.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -223,10 +223,7 @@ runtimeFunctions.retire = `const retire = () => {
223223
thread.target.runtime.sequencer.retireThread(thread);
224224
}`;
225225

226-
runtimeFunctions.NaNToZero = `const NaNToZero = value => {
227-
if (isNaN(value)) return 0;
228-
return value;
229-
}`;
226+
runtimeFunctions.NaNToZero = `const NaNToZero = value => isNaN(value) ? 0 : value`;
230227

231228
/**
232229
* Scratch cast to boolean.

0 commit comments

Comments
 (0)