Skip to content

Instantly share code, notes, and snippets.

@jrf0110
Last active August 29, 2015 14:16
Show Gist options
  • Save jrf0110/f128ef1008fc958b83b2 to your computer and use it in GitHub Desktop.
Save jrf0110/f128ef1008fc958b83b2 to your computer and use it in GitHub Desktop.

I'm having an issue with arrow functions:

~ iosjs --version
v1.3.0

That looks like iosjs and not node on accident.

~ iojs -e "console.log('hi')"
hi
iojs -e "console.log( Promise )"
[Function: Promise]

So far so good.

~ iojs -e "() => {}"
[eval]:1
() => {}
 ^
SyntaxError: Unexpected token )
    at Object.exports.runInThisContext (vm.js:53:16)
    at Object.<anonymous> ([eval]-wrapper:6:22)
    at Module._compile (module.js:444:26)
    at evalScript (node.js:413:25)
    at startup (node.js:72:7)
    at node.js:799:3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment