Skip to content

Commit e783c94

Browse files
committed
build: compile with C++20 support
Closes: nodejs#45402
1 parent 5fb6305 commit e783c94

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

common.gypi

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@
285285
'VCCLCompilerTool': {
286286
'AdditionalOptions': [
287287
'/Zc:__cplusplus',
288-
'-std:c++17'
288+
'-std:c++20'
289289
],
290290
'BufferSecurityCheck': 'true',
291291
'DebugInformationFormat': 1, # /Z7 embed info in .obj files
@@ -439,7 +439,7 @@
439439
}],
440440
[ 'OS in "linux freebsd openbsd solaris android aix os400 cloudabi"', {
441441
'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
442-
'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++17' ],
442+
'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++20' ],
443443
'defines': [ '__STDC_FORMAT_MACROS' ],
444444
'ldflags': [ '-rdynamic' ],
445445
'target_conditions': [
@@ -607,7 +607,7 @@
607607
['clang==1', {
608608
'xcode_settings': {
609609
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
610-
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++17', # -std=gnu++17
610+
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++20', # -std=gnu++20
611611
'CLANG_CXX_LIBRARY': 'libc++',
612612
},
613613
}],

0 commit comments

Comments
 (0)