mirror of https://github.com/lukechilds/node.git
Browse Source
Enable support for standalone block statements. ```js node 🙈 ₹ git:(upstream ⚡ bare-block) ./node > { var x = 3; console.log(x); } 3 undefined > {} {} > { x:1, y:"why not", z: function() {} } { x: 1, y: 'why not', z: [Function] } > ``` For the ambiguous inputs like `{ x }`, the existing REPL behaviour (ES6 literal shorthand) is preserved (prefers expression over statement). Fixes: https://github.com/nodejs/node/issues/5576 PR-URL: https://github.com/nodejs/node/pull/5581 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Evan Lucas <evanlucas@me.com>process-exit-stdio-flushing
Prince J Wesley
9 years ago
committed by
James M Snell
2 changed files with 19 additions and 6 deletions
Loading…
Reference in new issue