Should Error#message be enumerable?

Mathias Bynens mathias at
Sun Sep 4 23:53:52 PDT 2011

In most environments, Error#message is enumerable, e.g.

    try {
      LOLWAT; // throws a ReferenceError
    } catch(e) {
      for (var i in e) {

This enumerates the properties on the Error object and logs them one
by one to the console.

This behavior recently changed in v8, causing me to file this bug: However, the
comments (starting at have confused

Could anyone please clarify what the spec says on this topic?

More information about the es-discuss mailing list