Created
April 8, 2011 09:57
-
-
Save aseemk/909581 to your computer and use it in GitHub Desktop.
Streamline's compiler chokes on valid JS when a function happens to have a keyword name.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ node-streamline -c truthy_.js | |
$ node-streamline -c true_.js | |
/usr/lib/node/.npm/streamline/0.1.11/package/lib/transform.js:1549 | |
throw new Error(message); | |
^ | |
Error: error streamlining source: Missing identifier on line 5 | |
at Object.transform (/usr/lib/node/.npm/streamline/0.1.11/package/lib/transform.js:1549:10) | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:48:30 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:43:206 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:2:221 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:42:361 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:2:221 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:42:251 | |
at /usr/lib/node/.npm/streamline/0.1.11/package/lib/compile.js:2:221 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('should'); | |
var foo = true; | |
setTimeout(_, 1000); | |
foo.should.be.true('Streamline fails to compile this.'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('should'); | |
var foo = true; | |
setTimeout(_, 1000); | |
foo.should.be.truthy('Streamline compiles this fine.'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment