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 26a09e5

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 db610b9 commit 26a09e5
Copy full SHA for 26a09e5

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
@@ -360,9 +360,9 @@ Maybe<void> KVStore::AssignToObject(v8::Isolate* isolate,
360360
}
361361

362362
struct TraceEnvVarOptions {
363-
bool print_message : 1 = 0;
364-
bool print_js_stack : 1 = 0;
365-
bool print_native_stack : 1 = 0;
363+
bool print_message : 1 = false;
364+
bool print_js_stack : 1 = false;
365+
bool print_native_stack : 1 = false;
366366
};
367367

368368
template <typename... Args>
@@ -387,13 +387,13 @@ TraceEnvVarOptions GetTraceEnvVarOptions(Environment* env) {
387387
? env->options()
388388
: per_process::cli_options->per_isolate->per_env;
389389
if (cli_options->trace_env) {
390-
options.print_message = 1;
390+
options.print_message = true;
391391
};
392392
if (cli_options->trace_env_js_stack) {
393-
options.print_js_stack = 1;
393+
options.print_js_stack = true;
394394
};
395395
if (cli_options->trace_env_native_stack) {
396-
options.print_native_stack = 1;
396+
options.print_native_stack = true;
397397
};
398398
return options;
399399
}

0 commit comments

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