Skip to content

process: rename and deprecate process.reallyExit(), optionally expose result. #6509

@eljefedelrodeodeljefe

Description

@eljefedelrodeodeljefe
  • Version: all
  • Platform: all
  • Subsystem: process

In the wake of #6456 I want to suggest to rename process.reallyExit() as it's name is poorly chosen. It was introduced in f6a7fe2 and imo doesn't fit the intention of the commit - the repo was young back then.

An adequate name would be os.exit() since the exit call is implemented by the OSes differently. Optionally we could think about exposing this via documentation, since it also eases the API inconsistencies related - it would basically say, if you really want to exit, no matter what, call this.

For deprecation purposes we could alias this one in lib/process.js.

For API examples see other modern languages.

It's also doubtful whether the use of exit(3) is correct in that context and _Exit(3) (see here) would have been more appropriate. Discussion would be more academic though, imo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    processIssues and PRs related to the process subsystem.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions