Skip to content

Commit 0065fd6

Browse files
committed
build: compile with C++20 support
Closes: nodejs#45402
1 parent 4107ce0 commit 0065fd6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

common.gypi

+3-3
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@
280280
'VCCLCompilerTool': {
281281
'AdditionalOptions': [
282282
'/Zc:__cplusplus',
283-
'-std:c++17'
283+
'-std:c++20'
284284
],
285285
'BufferSecurityCheck': 'true',
286286
'target_conditions': [
@@ -403,7 +403,7 @@
403403
}],
404404
[ 'OS in "linux freebsd openbsd solaris android aix cloudabi"', {
405405
'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
406-
'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++17' ],
406+
'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++20' ],
407407
'defines': [ '__STDC_FORMAT_MACROS' ],
408408
'ldflags': [ '-rdynamic' ],
409409
'target_conditions': [
@@ -543,7 +543,7 @@
543543
['clang==1', {
544544
'xcode_settings': {
545545
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
546-
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++17', # -std=gnu++17
546+
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++20', # -std=gnu++20
547547
'CLANG_CXX_LIBRARY': 'libc++',
548548
},
549549
}],

0 commit comments

Comments
 (0)