From 0a21b06a26ff32b8d112c0f9756f21cdc6337494 Mon Sep 17 00:00:00 2001 From: Kuba Mracek Date: Sat, 1 Jan 2022 20:14:39 -0800 Subject: [PATCH] Fix propagation of SWIFT_ENABLE_REFLECTION from CMake into lit.cfg and re-enable 'REQUIRES: reflection' tests --- test/CMakeLists.txt | 1 + test/stdlib/Error.swift | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 5bec5d4172e75..110a9b7c7aa29 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -199,6 +199,7 @@ normalize_boolean_spelling(SWIFT_RUN_TESTS_WITH_HOST_COMPILER) normalize_boolean_spelling(SWIFT_RUNTIME_ENABLE_LEAK_CHECKER) normalize_boolean_spelling(SWIFT_OPTIMIZED) normalize_boolean_spelling(SWIFT_STDLIB_SINGLE_THREADED_RUNTIME) +normalize_boolean_spelling(SWIFT_ENABLE_REFLECTION) normalize_boolean_spelling(SWIFT_ENABLE_RUNTIME_FUNCTION_COUNTERS) normalize_boolean_spelling(SWIFT_HAVE_LIBXML2) normalize_boolean_spelling(SWIFT_INCLUDE_TOOLS) diff --git a/test/stdlib/Error.swift b/test/stdlib/Error.swift index 102c75a51149a..5e19d1b6372ba 100644 --- a/test/stdlib/Error.swift +++ b/test/stdlib/Error.swift @@ -134,7 +134,7 @@ ErrorTests.test("try!/location") .skip(.custom({ _isFastAssertConfiguration() }, reason: "trap is not guaranteed to happen in -Ounchecked")) .crashOutputMatches(shouldCheckErrorLocation() - ? "main/Error.swift:140" + ? "main/Error.swift:\(#line + 4)" : "") .code { expectCrashLater()