tc39 / eshost

A uniform wrapper around a multitude of ECMAScript hosts. CLI: https://github.com/bterlson/eshost-cli
Other
142 stars 36 forks source link

Throwing a string does not report correctly #67

Open ljharb opened 6 years ago

ljharb commented 6 years ago

A file of:

throw new Error('foo');

provides these results:

#### ch
Error: foo

#### v8
Error: foo

#### sm
Error: foo

#### jsc
Error: foo

A file of:

throw 'foo';

provides these results:

#### ch
foo: undefined

#### sm

#### v8
foo: undefined

#### jsc
foo: undefined

This is both unclear that it threw, but also, spidermonkey is reporting the wrong result.