Skip to content

Commit 82914d1

Browse files
authored
Merge pull request #76986 from rintaro/newparservalidation-on-by-default
[build-script] Enable new parser validation by default
2 parents 4d262df + 4616c77 commit 82914d1

File tree

4 files changed

+3
-9
lines changed

4 files changed

+3
-9
lines changed

lib/Frontend/CompilerInvocation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1691,7 +1691,7 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
16911691
Opts.DisableDynamicActorIsolation |=
16921692
Args.hasArg(OPT_disable_dynamic_actor_isolation);
16931693

1694-
#if SWIFT_ENABLE_EXPERIMENTAL_PARSER_VALIDATION
1694+
#if !defined(NDEBUG) && SWIFT_ENABLE_EXPERIMENTAL_PARSER_VALIDATION
16951695
/// Enable round trip parsing via the new swift parser unless it is disabled
16961696
/// explicitly. The new Swift parser can have mismatches with C++ parser -
16971697
/// rdar://118013482 Use this flag to disable round trip through the new

utils/build-presets.ini

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1996,7 +1996,6 @@ skstresstester
19961996
sourcekit-lsp
19971997
install-swiftformat
19981998
skip-test-swift=false
1999-
enable-experimental-parser-validation=true
20001999

20012000
[preset: buildbot_swiftsyntax_linux]
20022001
mixin-preset=mixin_swiftpm_package_linux_platform
@@ -2008,7 +2007,6 @@ swiftsyntax-enable-test-fuzzing
20082007
sourcekit-lsp
20092008
swiftformat
20102009
install-swiftformat
2011-
enable-experimental-parser-validation=true
20122010

20132011
#===------------------------------------------------------------------------===#
20142012
# Test Swift Format
@@ -2997,14 +2995,12 @@ mixin-preset=source_compat_suite_macos_base
29972995
debug
29982996
assertions
29992997
cross-compile-hosts=macosx-arm64
3000-
enable-experimental-parser-validation=true
30012998

30022999
[preset: source_compat_suite_macos_RA]
30033000
mixin-preset=source_compat_suite_macos_base
30043001
release
30053002
assertions
30063003
cross-compile-hosts=macosx-arm64
3007-
enable-experimental-parser-validation=true
30083004

30093005
[preset: source_compat_suite_macos_R]
30103006
mixin-preset=source_compat_suite_macos_base
@@ -3022,13 +3018,11 @@ cross-compile-hosts=macosx-arm64
30223018
mixin-preset=source_compat_suite_linux_base
30233019
debug
30243020
assertions
3025-
enable-experimental-parser-validation=true
30263021

30273022
[preset: source_compat_suite_linux_RA]
30283023
mixin-preset=source_compat_suite_linux_base
30293024
release
30303025
assertions
3031-
enable-experimental-parser-validation=true
30323026

30333027
[preset: source_compat_suite_linux_R]
30343028
mixin-preset=source_compat_suite_linux_base

utils/build_swift/build_swift/driver_arguments.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1494,7 +1494,7 @@ def create_argument_parser():
14941494
help='Enable Volatile module.')
14951495

14961496
option('--enable-experimental-parser-validation', toggle_true,
1497-
default=False,
1497+
default=True,
14981498
help='Enable experimental Swift Parser validation by default.')
14991499

15001500
# -------------------------------------------------------------------------

utils/build_swift/tests/expected_options.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@
184184
'enable_experimental_nonescapable_types': False,
185185
'enable_experimental_string_processing': True,
186186
'enable_experimental_observation': True,
187-
'enable_experimental_parser_validation': False,
187+
'enable_experimental_parser_validation': True,
188188
'swift_enable_backtracing': True,
189189
'enable_synchronization': True,
190190
'enable_volatile': True,

0 commit comments

Comments
 (0)