Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src: turn embedder api overload into default argument #43629

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -875,13 +875,6 @@ int ProcessGlobalArgs(std::vector<std::string>* args,

static std::atomic_bool init_called{false};

int InitializeNodeWithArgs(std::vector<std::string>* argv,
std::vector<std::string>* exec_argv,
std::vector<std::string>* errors) {
return InitializeNodeWithArgs(argv, exec_argv, errors,
ProcessFlags::kNoFlags);
}

int InitializeNodeWithArgs(std::vector<std::string>* argv,
std::vector<std::string>* exec_argv,
std::vector<std::string>* errors,
Expand Down
7 changes: 1 addition & 6 deletions src/node.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,16 +250,11 @@ NODE_EXTERN int Stop(Environment* env);
// from argv, fill exec_argv, and possibly add errors resulting from parsing
// the arguments to `errors`. The return value is a suggested exit code for the
// program; If it is 0, then initializing Node.js succeeded.
NODE_EXTERN int InitializeNodeWithArgs(
std::vector<std::string>* argv,
std::vector<std::string>* exec_argv,
std::vector<std::string>* errors);
// TODO(zcbenz): Turn above overloaded version into below's default argument.
NODE_EXTERN int InitializeNodeWithArgs(
std::vector<std::string>* argv,
std::vector<std::string>* exec_argv,
std::vector<std::string>* errors,
ProcessFlags::Flags flags);
ProcessFlags::Flags flags = ProcessFlags::kNoFlags);

enum OptionEnvvarSettings {
kAllowedInEnvironment,
Expand Down