Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 26c6045

Browse filesBrowse files
tniessenaduh95
authored andcommitted
src: use bool literals in TraceEnvVarOptions
The bit fields are declared as `bool` fields, yet are assigned integer values. PR-URL: #61425 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
1 parent a810f5c commit 26c6045
Copy full SHA for 26c6045

1 file changed

+6-6Lines changed: 6 additions & 6 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/node_env_var.cc‎

Copy file name to clipboardExpand all lines: src/node_env_var.cc
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -358,9 +358,9 @@ Maybe<void> KVStore::AssignToObject(v8::Isolate* isolate,
358358
}
359359

360360
struct TraceEnvVarOptions {
361-
bool print_message : 1 = 0;
362-
bool print_js_stack : 1 = 0;
363-
bool print_native_stack : 1 = 0;
361+
bool print_message : 1 = false;
362+
bool print_js_stack : 1 = false;
363+
bool print_native_stack : 1 = false;
364364
};
365365

366366
template <typename... Args>
@@ -385,13 +385,13 @@ TraceEnvVarOptions GetTraceEnvVarOptions(Environment* env) {
385385
? env->options()
386386
: per_process::cli_options->per_isolate->per_env;
387387
if (cli_options->trace_env) {
388-
options.print_message = 1;
388+
options.print_message = true;
389389
};
390390
if (cli_options->trace_env_js_stack) {
391-
options.print_js_stack = 1;
391+
options.print_js_stack = true;
392392
};
393393
if (cli_options->trace_env_native_stack) {
394-
options.print_native_stack = 1;
394+
options.print_native_stack = true;
395395
};
396396
return options;
397397
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.