Skip to content

arguments property of ReferenceError instance? #11558

Closed
@vsemozhetbyt

Description

@vsemozhetbyt
  • Version:
  • Platform: Windows 7 x64
  • Subsystem: doc, errors

errors.md states:

ReferenceError instances will have an error.arguments property whose value is an array containing a single element: a string representing the variable that was not defined.

However, it seems this property does not exixst anymore in the actual Node.js versions:

try {
  doesNotExist;
} catch (err) {
  console.log(Object.getOwnPropertyNames(err));
}
  // v8 4.5.103.45 (Node.js 4.8.0 x64)

[ 'stack', 'message' ]

  // v8 5.1.281.93 (Node.js 6.10.0 x64)

[ 'stack', 'message' ]

  // v8 5.5.372.40 (Node.js 7.6.0 x64)

[ 'stack', 'message' ]

  // v8 5.6.326.55 (Node.js 8.0.0-nightly20170222a1802e670d x64)

[ 'stack', 'message' ]

  // v8 5.8.202 (Node.js 8.0.0-pre x64)

[ 'stack', 'message' ]

Is this an unintended loss or is this property removed intentionally?

Metadata

Metadata

Assignees

No one assigned

    Labels

    docIssues and PRs related to the documentations.errorsIssues and PRs related to JavaScript errors originated in Node.js core.v8 engineIssues and PRs related to the V8 dependency.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions