From 204ee92b2a7e74030376988c0d1bb23efd59d69e Mon Sep 17 00:00:00 2001 From: Alexander Cyon Date: Thu, 8 Aug 2024 18:58:57 +0200 Subject: [PATCH] [test/*] Fix typos misc folders in test --- test/APIJSON/availability.swift | 4 ++-- test/ASTGen/stmts.swift | 2 +- .../associated_type_inference.swift | 2 +- ...ssociated_type_inference_tautology_4.swift | 2 +- .../issue-65073-substmap.swift | 2 +- test/CAS/bridging-header.swift | 2 +- .../IncompleteTypes/complete-types.m | 2 +- ...y-forward-declaring-complete-swift-types.h | 2 +- test/ConstExtraction/ExtractCoerce.swift | 6 +++--- test/Constraints/closures.swift | 2 +- test/Constraints/diagnostics.swift | 2 +- test/Constraints/dynamic_lookup.swift | 2 +- test/DebugInfo/sroa_debug_value.sil | 2 +- test/DebugInfo/sroa_mem2reg.sil | 2 +- test/DebugInfo/sroa_mem2reg_tuple.sil | 2 +- .../loaded_module_trace_directness_2.swift | 2 +- test/Generics/conditional_conformances.swift | 2 +- .../unit-custom-output-path-driver.swift | 2 +- .../Index/Store/unit-custom-output-path.swift | 2 +- test/Inputs/lazy_typecheck_client.swift | 2 +- test/Interpreter/SDK/Inputs/OldABI/OldABI.mm | 2 +- test/Interpreter/init_accessors.swift | 20 +++++++++---------- test/Macros/lit.local.cfg | 2 +- test/Macros/macro_expand_closure.swift | 2 +- .../Macros/macro_plugin_disable_sandbox.swift | 2 +- test/Macros/macro_swiftdeps.swift | 2 +- .../async_sequence_conformance.swift | 4 ++-- test/ModuleInterface/features.swift | 2 +- .../availability_query_unavailability.swift | 2 +- test/Profiler/coverage_result_builder.swift | 6 +++--- test/Profiler/unmapped.swift | 4 ++-- test/Prototypes/BigInt.swift | 6 +++--- .../borrow_extract_validate.sil | 18 ++++++++--------- .../SIL/OwnershipVerifier/borrow_validate.sil | 20 +++++++++---------- test/SIL/Serialization/public_external.sil | 2 +- test/SPI/accidental-reexport.swift | 14 ++++++------- ...onal_deps_of_binary_testable_imports.swift | 2 +- .../optional_deps_of_testable_imports.swift | 2 +- .../optional_transitive_dep_load_fail.swift | 2 +- test/Sema/accessibility.swift | 10 +++++----- test/Sema/availability_versions.swift | 2 +- .../Sema/availability_versions_objc_api.swift | 2 +- test/Sema/diag_constantness_check.swift | 2 +- test/Sema/superfluously-public-imports.swift | 4 ++-- test/attr/attr_availability_narrow.swift | 2 +- test/decl/var/init_accessors.swift | 6 +++--- test/embedded/FixedArray.swift | 4 ++-- .../Inputs/ExperimentalFixedArray.swift | 4 ++-- test/embedded/ouroboros-bug.swift | 2 +- test/expr/unary/if_expr.swift | 6 +++--- test/expr/unary/switch_expr.swift | 6 +++--- test/lit.cfg | 6 +++--- .../simplify_long_number.swift | 12 +++++------ .../Outputs/textual/foo.swift.expected | 2 +- .../refactoring/SyntacticRename/textual.swift | 2 +- test/stdlib/SwiftObjectNSObject.swift | 2 +- test/stdlib/SwiftValueNSObject.swift | 2 +- 57 files changed, 118 insertions(+), 118 deletions(-) diff --git a/test/APIJSON/availability.swift b/test/APIJSON/availability.swift index f55689d651adb..d726837b5735e 100644 --- a/test/APIJSON/availability.swift +++ b/test/APIJSON/availability.swift @@ -18,7 +18,7 @@ public func callUnavailable() {} public func availableOnlyOnActiveOS() {} @available(tvOS, unavailable) -public func unavailableOnSeperateOS() {} +public func unavailableOnSeparateOS() {} extension A { @available(macOS 12, *) @@ -114,7 +114,7 @@ extension A { // CHECK-NEXT: "introduced": "10.10" // CHECK-NEXT: }, // CHECK-NEXT: { -// CHECK-NEXT: "name": "_$s8MyModule23unavailableOnSeperateOSyyF", +// CHECK-NEXT: "name": "_$s8MyModule23unavailableOnSeparateOSyyF", // CHECK-NEXT: "access": "public", // CHECK-NEXT: "file": "SOURCE_DIR/test/APIJSON/availability.swift", // CHECK-NEXT: "linkage": "exported" diff --git a/test/ASTGen/stmts.swift b/test/ASTGen/stmts.swift index f0f71b20b0574..b474348be30f1 100644 --- a/test/ASTGen/stmts.swift +++ b/test/ASTGen/stmts.swift @@ -129,7 +129,7 @@ struct GenericTypeWithYields { } } -/* FXIME: yield(...) is parsed as an expression. ASTGen needs to onvert it to a statments. +/* FXIME: yield(...) is parsed as an expression. ASTGen needs to convert it to a statement. subscript(u: U) -> (T,U) { _read { yield ((storedProperty!, u)) diff --git a/test/AssociatedTypeInference/associated_type_inference.swift b/test/AssociatedTypeInference/associated_type_inference.swift index 6a45368643eb4..ca787690f0adf 100644 --- a/test/AssociatedTypeInference/associated_type_inference.swift +++ b/test/AssociatedTypeInference/associated_type_inference.swift @@ -449,7 +449,7 @@ struct X15d : P15d { } // FIXME: Better diagnostic here? struct X15g : P15g { } // expected-error{{type 'X15g' does not conform to protocol 'P15g'}} expected-note {{add stubs for conformance}} -// Associated type defaults in overidden associated types that require +// Associated type defaults in overridden associated types that require // substitution. struct X16 { } diff --git a/test/AssociatedTypeInference/associated_type_inference_tautology_4.swift b/test/AssociatedTypeInference/associated_type_inference_tautology_4.swift index b082a42099a5f..8e470d41112b7 100644 --- a/test/AssociatedTypeInference/associated_type_inference_tautology_4.swift +++ b/test/AssociatedTypeInference/associated_type_inference_tautology_4.swift @@ -9,7 +9,7 @@ protocol P2 { } struct S2: P2 { - // These are not candiate witnesses for the requirement. + // These are not candidate witnesses for the requirement. func f(_: Float, _: Array) {} func f(_: String, _: Array) {} diff --git a/test/AutoDiff/compiler_crashers_fixed/issue-65073-substmap.swift b/test/AutoDiff/compiler_crashers_fixed/issue-65073-substmap.swift index 8fe8e5b870700..8e4d01f1bb234 100644 --- a/test/AutoDiff/compiler_crashers_fixed/issue-65073-substmap.swift +++ b/test/AutoDiff/compiler_crashers_fixed/issue-65073-substmap.swift @@ -4,7 +4,7 @@ // We need to ensure we are not dropping the substitution map during the // derivative type calculation in sil combiner that causes errors in the // subsequent optimizations as we're ending with invalid "recursive" -// subsitutions +// substitutions import _Differentiation; diff --git a/test/CAS/bridging-header.swift b/test/CAS/bridging-header.swift index bc0691e9af0f9..ee4e6e0a4bab0 100644 --- a/test/CAS/bridging-header.swift +++ b/test/CAS/bridging-header.swift @@ -65,7 +65,7 @@ // RUN: %target-swift-frontend -cache-compile-job -module-name Test -O -cas-path %t/cas @%t/MyApp.cmd %t/test.swift \ // RUN: -emit-module -o %t/Test.swiftmodule -/// Importing binary module with bridging header built from CAS from a regluar build. +/// Importing binary module with bridging header built from CAS from a regular build. /// This should succeed even it is also importing a bridging header that shares same header dependencies (with proper header guard). // RUN: %target-swift-frontend -typecheck -module-name User -swift-version 5 \ // RUN: -disable-implicit-string-processing-module-import -disable-implicit-concurrency-module-import \ diff --git a/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/complete-types.m b/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/complete-types.m index 1fefda2370731..e143e2705262a 100644 --- a/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/complete-types.m +++ b/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/complete-types.m @@ -14,6 +14,6 @@ void takeACompleteInterface(ForwardDeclaredInterface *param) { [param doSomethingForwardDeclaredInterfacesCan]; } void takeACompleteProtocol(NSObject *param) { - NSLog(@"takeACompleteProcotol"); + NSLog(@"takeACompleteProtocol"); [param doSomethingForwardDeclaredProtocolsCan]; } diff --git a/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/objc-library-forward-declaring-complete-swift-types.h b/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/objc-library-forward-declaring-complete-swift-types.h index 9f3e440b15bf9..ab8a33f1bafa4 100644 --- a/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/objc-library-forward-declaring-complete-swift-types.h +++ b/test/ClangImporter/Inputs/custom-modules/IncompleteTypes/objc-library-forward-declaring-complete-swift-types.h @@ -17,7 +17,7 @@ void takeASubscript(subscript *param); subscript* returnASubscript(); // There is a Swift protocol, @objc protocol ShadowedProtocol, but -// since here we are refering to a class and not a protocol, this +// since here we are referring to a class and not a protocol, this // shouldn't be an issue. ShadowedProtocol* returnANativeObjCClassShadowedProtocol(); diff --git a/test/ConstExtraction/ExtractCoerce.swift b/test/ConstExtraction/ExtractCoerce.swift index d6cdcb4a4776d..d89be0463aa86 100644 --- a/test/ConstExtraction/ExtractCoerce.swift +++ b/test/ConstExtraction/ExtractCoerce.swift @@ -4,7 +4,7 @@ // RUN: %target-swift-frontend -typecheck -emit-const-values-path %t/ExtractLiterals.swiftconstvalues -const-gather-protocols-file %t/protocols.json -primary-file %s // RUN: cat %t/ExtractLiterals.swiftconstvalues 2>&1 | %FileCheck %s -struct CoercableThing : ExpressibleByStringLiteral { +struct CoercibleThing : ExpressibleByStringLiteral { let thing: String public init(unicodeScalarLiteral value: String) { self.init(stringLiteral: value) @@ -17,8 +17,8 @@ struct CoercableThing : ExpressibleByStringLiteral { protocol MyProto {} public struct TestStruct : MyProto { - let foo: CoercableThing = "foo" - let bar: CoercableThing = CoercableThing("bar") + let foo: CoercibleThing = "foo" + let bar: CoercibleThing = CoercibleThing("bar") } // CHECK: "label": "foo", diff --git a/test/Constraints/closures.swift b/test/Constraints/closures.swift index b79a297961fb1..d56f7e18a9c94 100644 --- a/test/Constraints/closures.swift +++ b/test/Constraints/closures.swift @@ -34,7 +34,7 @@ _ = f0(X2(), {$0.g()}) func inoutToSharedConversions() { func fooOW(_ f : (__owned T) -> U) {} - fooOW({ (x : Int) in return Int(5) }) // defaut-to-'__owned' allowed + fooOW({ (x : Int) in return Int(5) }) // default-to-'__owned' allowed fooOW({ (x : __owned Int) in return Int(5) }) // '__owned'-to-'__owned' allowed fooOW({ (x : __shared Int) in return Int(5) }) // '__shared'-to-'__owned' allowed fooOW({ (x : inout Int) in return Int(5) }) // expected-error {{cannot convert value of type '(inout Int) -> Int' to expected argument type '(__owned Int) -> Int'}} diff --git a/test/Constraints/diagnostics.swift b/test/Constraints/diagnostics.swift index 07bb6e512c4c2..63298c0ed6d87 100644 --- a/test/Constraints/diagnostics.swift +++ b/test/Constraints/diagnostics.swift @@ -173,7 +173,7 @@ func rdar21080030() { if s.count() == 0 {} // expected-error {{cannot call value of non-function type 'Int'}} } -// QoI: problem with return type inference mis-diagnosed as invalid arguments +// QoI: problem with return type inference misdiagnosed as invalid arguments func r21248136() -> T { preconditionFailure() } // expected-note 2 {{in call to function 'r21248136()'}} r21248136() // expected-error {{generic parameter 'T' could not be inferred}} diff --git a/test/Constraints/dynamic_lookup.swift b/test/Constraints/dynamic_lookup.swift index b221248786b27..676d6958d9a87 100644 --- a/test/Constraints/dynamic_lookup.swift +++ b/test/Constraints/dynamic_lookup.swift @@ -478,7 +478,7 @@ class AmbiguityA : NSObject { } -class AmbuguityB : NSObject { +class AmbiguityB : NSObject { @objc class var testProp: B { get { B() } } } diff --git a/test/DebugInfo/sroa_debug_value.sil b/test/DebugInfo/sroa_debug_value.sil index b8fdd4bf5e267..f65d2d4d64ca8 100644 --- a/test/DebugInfo/sroa_debug_value.sil +++ b/test/DebugInfo/sroa_debug_value.sil @@ -28,7 +28,7 @@ sil hidden @foo : $@convention(thin) (Int64, Int64) -> Int64 { bb0(%0 : $Int64, %1 : $Int64): %4 = alloc_stack $MyStruct, var, name "my_struct", loc "sroa.swift":8:9, scope 2 debug_value %4 : $*MyStruct, let, name "my_copy", expr op_deref, loc "sroa.swift":7:10, scope 2 - // Make sure SROA propagate the debug info to the splitted alloc_stack/debug_value instructions + // Make sure SROA propagate the debug info to the split alloc_stack/debug_value instructions // CHECK-SROA: %[[ALLOC_X:[0-9]+]] = alloc_stack $Int64, var // CHECK-SROA-SAME: (name "my_struct", loc "sroa.swift":8:9 // CHECK-SROA-SAME: type $MyStruct, expr op_fragment:#MyStruct.x diff --git a/test/DebugInfo/sroa_mem2reg.sil b/test/DebugInfo/sroa_mem2reg.sil index 2d114bb39b8c7..e0fec259946d6 100644 --- a/test/DebugInfo/sroa_mem2reg.sil +++ b/test/DebugInfo/sroa_mem2reg.sil @@ -32,7 +32,7 @@ bb0(%0 : $Int64, %1 : $Int64): debug_value %0 : $Int64, let, name "in_x", argno 1, loc "sroa.swift":7:10, scope 2 debug_value %1 : $Int64, let, name "in_y", argno 2, loc "sroa.swift":7:21, scope 2 %4 = alloc_stack $MyStruct, var, name "my_struct", loc "sroa.swift":8:9, scope 2 - // Make sure SROA propagate the debug info to the splitted alloc_stack instructions + // Make sure SROA propagate the debug info to the split alloc_stack instructions // CHECK-SROA: alloc_stack $Int64, var // CHECK-SROA-SAME: (name "my_struct", loc "sroa.swift":8:9 // CHECK-SROA-SAME: type $MyStruct, expr op_fragment:#MyStruct.x diff --git a/test/DebugInfo/sroa_mem2reg_tuple.sil b/test/DebugInfo/sroa_mem2reg_tuple.sil index e5926ccfbd1a8..0eb66137c5621 100644 --- a/test/DebugInfo/sroa_mem2reg_tuple.sil +++ b/test/DebugInfo/sroa_mem2reg_tuple.sil @@ -20,7 +20,7 @@ bb0(%0 : $Int64, %1 : $Int64): debug_value %1 : $Int64, let, name "in_y", argno 2, loc "sroa.swift":1:21, scope 2 %4 = alloc_stack $(x: Int64, y: Int64), var, name "my_tup", loc "sroa.swift":2:7, scope 3 - // Make sure SROA propagate the debug info to the splitted alloc_stack instructions + // Make sure SROA propagate the debug info to the split alloc_stack instructions // CHECK-SROA: alloc_stack $Builtin.Int64, var // CHECK-SROA-SAME: (name "my_tup", loc "sroa.swift":2:7 // CHECK-SROA-SAME: type $(x: Int64, y: Int64), expr op_tuple_fragment:$(x: Int64, y: Int64):0:op_fragment:#Int64._value diff --git a/test/Driver/loaded_module_trace_directness_2.swift b/test/Driver/loaded_module_trace_directness_2.swift index 4fbea42f7daf6..961a12fbc32b0 100644 --- a/test/Driver/loaded_module_trace_directness_2.swift +++ b/test/Driver/loaded_module_trace_directness_2.swift @@ -6,7 +6,7 @@ // Dependency graph: // // * CoreFilesystem - Swift module with generated ObjC header -// * FilesystemKit - ObjC module without overlay, has #import +// * FilesystemKit - ObjC module without overlay, has #import // * TestFilesystem - Swift module, has import CoreFilesystem or FilesystemKit. // // * CoreDaemon - ObjC module with overlay, the overlay has import DaemonKit diff --git a/test/Generics/conditional_conformances.swift b/test/Generics/conditional_conformances.swift index 6932258e5530a..80a9b1c95ee05 100644 --- a/test/Generics/conditional_conformances.swift +++ b/test/Generics/conditional_conformances.swift @@ -387,7 +387,7 @@ extension TwoDisjointConformances: P2 where T == String {} // FIXME: these cases should be equivalent (and both with the same output as the -// first), but the second one choses T as the representative of the +// first), but the second one chooses T as the representative of the // equivalence class containing both T and U in the extension's generic // signature, meaning the stored conditional requirement is T: P1, which isn't // true in the original type's generic signature. diff --git a/test/Index/Store/unit-custom-output-path-driver.swift b/test/Index/Store/unit-custom-output-path-driver.swift index 52b83767258b5..2e9ffd8de5685 100644 --- a/test/Index/Store/unit-custom-output-path-driver.swift +++ b/test/Index/Store/unit-custom-output-path-driver.swift @@ -139,7 +139,7 @@ // Check the unit output is based on "index-unit-output-path": // RUN: c-index-test core -print-unit %/t/idx_batch_with | %FileCheck -check-prefixes=INDEX_WITH %s // -// Check the unit output is not baed on the "output" values: +// Check the unit output is not based on the "output" values: // RUN: c-index-test core -print-unit %/t/idx_batch_with | %FileCheck -check-prefixes=INDEX_WITH_NEGATIVE %s // // C) Do the above again but with a fresh index store and using file lists. diff --git a/test/Index/Store/unit-custom-output-path.swift b/test/Index/Store/unit-custom-output-path.swift index ee46e228bc422..555a7b0980e7f 100644 --- a/test/Index/Store/unit-custom-output-path.swift +++ b/test/Index/Store/unit-custom-output-path.swift @@ -117,7 +117,7 @@ // Check the unit output is based on -index-unit-output-path: // RUN: c-index-test core -print-unit %t/idx_batch_with | %FileCheck -check-prefixes=INDEX_BATCH_WITH %s // -// Check the unit output is not baed on the -o values: +// Check the unit output is not based on the -o values: // RUN: c-index-test core -print-unit %t/idx_batch_with | %FileCheck -check-prefixes=INDEX_BATCH_WITH_NEGATIVE %s // // INDEX_BATCH_WITH: custom_main.o-{{.*}} diff --git a/test/Inputs/lazy_typecheck_client.swift b/test/Inputs/lazy_typecheck_client.swift index 938960138ae25..bde53360484a9 100644 --- a/test/Inputs/lazy_typecheck_client.swift +++ b/test/Inputs/lazy_typecheck_client.swift @@ -27,7 +27,7 @@ func testGlobalFunctions() { } } -func testGobalVars() { +func testGlobalVars() { let _: Int = publicGlobalVar let _: Int = publicGlobalVarTypealias let _: String = publicGlobalVarInferredType diff --git a/test/Interpreter/SDK/Inputs/OldABI/OldABI.mm b/test/Interpreter/SDK/Inputs/OldABI/OldABI.mm index 98d561cdec899..6e11717bda231 100644 --- a/test/Interpreter/SDK/Inputs/OldABI/OldABI.mm +++ b/test/Interpreter/SDK/Inputs/OldABI/OldABI.mm @@ -11,7 +11,7 @@ // Implementation of ObjC classes // with bits set to mimic the pre-stable Swift ABI -// and additional memory protection to detect mis-use +// and additional memory protection to detect misuse #if __has_include() #include diff --git a/test/Interpreter/init_accessors.swift b/test/Interpreter/init_accessors.swift index d8e2ee7c2bc64..523ba9f7fe4b1 100644 --- a/test/Interpreter/init_accessors.swift +++ b/test/Interpreter/init_accessors.swift @@ -140,7 +140,7 @@ struct TestNoInitAndInit { var pointX: Int { @storageRestrictions(accesses: x) - init(initalValue) { + init(initialValue) { } get { x } @@ -559,7 +559,7 @@ func test_effects_are_still_supported() { } test_effects_are_still_supported() -// CHEKC: effects-support-test: Test(_a: 42, b: 0) +// CHECK: effects-support-test: Test(_a: 42, b: 0) func test_memberwise_without_stored_properties() { struct Test { @@ -819,9 +819,9 @@ do { print(TestDefaultInitializable()) print(TestDefaultInitializable(a: 42)) - struct TestMixedDefaultInitalizable : CustomStringConvertible { + struct TestMixedDefaultInitializable : CustomStringConvertible { var description: String { - "TestMixedDefaultInitalizable(a: \(a), b: \(b))" + "TestMixedDefaultInitializable(a: \(a), b: \(b))" } var a: Int? { @@ -838,15 +838,15 @@ do { } } - print(TestMixedDefaultInitalizable()) - print(TestMixedDefaultInitalizable(b: "Hello")) - print(TestMixedDefaultInitalizable(a: 42)) + print(TestMixedDefaultInitializable()) + print(TestMixedDefaultInitializable(b: "Hello")) + print(TestMixedDefaultInitializable(a: 42)) } // CHECK: TestDefaultInitializable(a: nil) // CHECK-NEXT: TestDefaultInitializable(a: Optional(42)) -// CHECK-NEXT: TestMixedDefaultInitalizable(a: nil, b: Optional("")) -// CHECK-NEXT: TestMixedDefaultInitalizable(a: nil, b: Optional("Hello")) -// CHECK-NEXT: TestMixedDefaultInitalizable(a: nil, b: Optional("")) +// CHECK-NEXT: TestMixedDefaultInitializable(a: nil, b: Optional("")) +// CHECK-NEXT: TestMixedDefaultInitializable(a: nil, b: Optional("Hello")) +// CHECK-NEXT: TestMixedDefaultInitializable(a: nil, b: Optional("")) do { struct TestNonMutatingSetDefault { diff --git a/test/Macros/lit.local.cfg b/test/Macros/lit.local.cfg index fe1101a502530..da65b67f629b7 100644 --- a/test/Macros/lit.local.cfg +++ b/test/Macros/lit.local.cfg @@ -2,7 +2,7 @@ if 'asserts' not in config.available_features: config.unsupported = True -config.subsitutions = list(config.substitutions) +config.substitutions = list(config.substitutions) def get_target_os(): import re diff --git a/test/Macros/macro_expand_closure.swift b/test/Macros/macro_expand_closure.swift index 28feb98b40d32..432b6c6ac0728 100644 --- a/test/Macros/macro_expand_closure.swift +++ b/test/Macros/macro_expand_closure.swift @@ -17,7 +17,7 @@ func multiStatementInference() -> Int { #multiStatement() } -// The closure intruduced by the macro expansion should not contain any inline +// The closure introduced by the macro expansion should not contain any inline // locations, but instead point directly into the macro buffer. // CHECK-SIL: sil_scope [[S0:[0-9]+]] { loc "@__swiftmacro_9MacroUser0031macro_expand_closureswift_yFFIifMX16_2_14multiStatementfMf_.swift":1:1 parent @$s9MacroUser23multiStatementInferenceSiyFSiyXEfU_ // CHECK-SIL: sil_scope [[S2:[0-9]+]] { loc "@__swiftmacro_9MacroUser0031macro_expand_closureswift_yFFIifMX16_2_14multiStatementfMf_.swift":2:14 parent [[S0]] } diff --git a/test/Macros/macro_plugin_disable_sandbox.swift b/test/Macros/macro_plugin_disable_sandbox.swift index e744554f47286..c12294e486706 100644 --- a/test/Macros/macro_plugin_disable_sandbox.swift +++ b/test/Macros/macro_plugin_disable_sandbox.swift @@ -1,6 +1,6 @@ // REQUIRES: swift_swift_parser -// sandbox-exec is only avaiable in Darwin +// sandbox-exec is only available in Darwin // REQUIRES: OS=macosx // RUN: %empty-directory(%t) diff --git a/test/Macros/macro_swiftdeps.swift b/test/Macros/macro_swiftdeps.swift index 0951863a27c63..911990003fe4e 100644 --- a/test/Macros/macro_swiftdeps.swift +++ b/test/Macros/macro_swiftdeps.swift @@ -103,7 +103,7 @@ // WITHOUT_PLUGIN-NOT: AssertPlugin // WITHOUT_PLUGIN-NOT: mock-plugin -// TRACE_WITH_PLGUIN: "swiftmacros":[ +// TRACE_WITH_PLUGIN: "swiftmacros":[ // TRACE_WITH_PLUGIN-DAG: {"name":"AssertPlugin","path":"{{.*}}AssertPlugin.{{(dylib|so|dll)}}"} // TRACE_WITH_PLUGIN-DAG: {"name":"StringifyPlugin","path":"{{.*}}StringifyPlugin.{{(dylib|so|dll)}}"} // TRACE_WITH_PLUGIN-DAG: {"name":"TestPlugin","path":"{{.*}}mock-plugin"} diff --git a/test/ModuleInterface/async_sequence_conformance.swift b/test/ModuleInterface/async_sequence_conformance.swift index c1015fc6911f1..078b659fcfef2 100644 --- a/test/ModuleInterface/async_sequence_conformance.swift +++ b/test/ModuleInterface/async_sequence_conformance.swift @@ -4,7 +4,7 @@ // REQUIRES: concurrency, OS=macosx -// CHECK: public struct SequenceAdapte +// CHECK: public struct SequenceAdapter @available(SwiftStdlib 5.1, *) public struct SequenceAdapter: AsyncSequence { // CHECK-LABEL: public struct AsyncIterator @@ -28,7 +28,7 @@ public struct SequenceAdapter: AsyncSequence { // CHECK-SAME: public typealias __AsyncSequence_Failure = Base.Failure } -// CHECK: public struct OtherSequenceAdapte +// CHECK: public struct OtherSequenceAdapter @available(SwiftStdlib 5.1, *) public struct OtherSequenceAdapter: AsyncSequence { // CHECK: public typealias Element = Base.Element diff --git a/test/ModuleInterface/features.swift b/test/ModuleInterface/features.swift index 1f8c8b8ceb6c4..914e0266d432a 100644 --- a/test/ModuleInterface/features.swift +++ b/test/ModuleInterface/features.swift @@ -19,7 +19,7 @@ // the uses of those features are guarded by appropriate #if's that allow older // compilers to skip over the uses of newer features. -// Some feature gaurds are retired when the first compiler that supports the +// Some feature guards are retired when the first compiler that supports the // feature is old enough. The --implicit-check-not arguments to FileCheck above // verify that those guards no longer pollute the emitted interface. diff --git a/test/Parse/availability_query_unavailability.swift b/test/Parse/availability_query_unavailability.swift index 85590d589ad1e..a70487e925d5f 100644 --- a/test/Parse/availability_query_unavailability.swift +++ b/test/Parse/availability_query_unavailability.swift @@ -65,7 +65,7 @@ if #unavailable(iOS 8.0) { if #unavailable(iOSApplicationExtension, unavailable) { // expected-error 2{{expected version number}} } -// Should this be a valid spelling since `#unvailable(*)` cannot be written? +// Should this be a valid spelling since `#unavailable(*)` cannot be written? if #unavailable() { // expected-error {{expected platform name}} } diff --git a/test/Profiler/coverage_result_builder.swift b/test/Profiler/coverage_result_builder.swift index be6874f87f641..7c04ceabc8c43 100644 --- a/test/Profiler/coverage_result_builder.swift +++ b/test/Profiler/coverage_result_builder.swift @@ -1,4 +1,4 @@ -// RUN: %target-swift-frontend -Xllvm -sil-full-demangle -profile-generate -profile-coverage-mapping -emit-sorted-sil -emit-sil -module-name coverage_functon_builder %s | %FileCheck %s +// RUN: %target-swift-frontend -Xllvm -sil-full-demangle -profile-generate -profile-coverage-mapping -emit-sorted-sil -emit-sil -module-name coverage_function_builder %s | %FileCheck %s // RUN: %target-swift-frontend -profile-generate -profile-coverage-mapping -emit-ir %s @resultBuilder @@ -11,7 +11,7 @@ struct Summer { } } -// CHECK-LABEL: sil_coverage_map {{.*}} "$s24coverage_functon_builder5test0SiyF" +// CHECK-LABEL: sil_coverage_map {{.*}} "$s25coverage_function_builder5test0SiyF" @Summer func test0() -> Int { // CHECK: [[@LINE-1]]:21 -> [[@LINE+3]]:2 : 0 @@ -19,7 +19,7 @@ func test0() -> Int { 12 } -// CHECK-LABEL: sil_coverage_map {{.*}} "$s24coverage_functon_builder5test1SiyF" +// CHECK-LABEL: sil_coverage_map {{.*}} "$s25coverage_function_builder5test1SiyF" @Summer func test1() -> Int { // CHECK: [[@LINE-1]]:21 -> [[@LINE+7]]:2 : 0 diff --git a/test/Profiler/unmapped.swift b/test/Profiler/unmapped.swift index 8ea472b527bfc..5911e10f8cd57 100644 --- a/test/Profiler/unmapped.swift +++ b/test/Profiler/unmapped.swift @@ -93,10 +93,10 @@ struct UnavailableType { var storedClosure: Int = { .random() ? 0 : 1 }() @Wrapper - var wrappered = .random() ? 0 : 1 + var wrapped = .random() ? 0 : 1 @Wrapper(wrappedValue: .random() ? 0 : 1) - var alsoWrappered: Int + var alsoWrapped: Int } @available(*, unavailable) diff --git a/test/Prototypes/BigInt.swift b/test/Prototypes/BigInt.swift index ca7725cede255..84b86d8dd3ce1 100644 --- a/test/Prototypes/BigInt.swift +++ b/test/Prototypes/BigInt.swift @@ -459,7 +459,7 @@ public struct _BigInt : return } - // Comare `lhs` and `rhs` so we can use `_unsignedSubtract` to subtract + // Compare `lhs` and `rhs` so we can use `_unsignedSubtract` to subtract // the smaller magnitude from the larger magnitude. switch lhs._compareMagnitude(to: rhs) { case .equal: @@ -1032,7 +1032,7 @@ public struct _BigInt : case lessThan, equal, greaterThan } - /// Returns whether this instance is less than, greather than, or equal to + /// Returns whether this instance is less than, greater than, or equal to /// the given value. func _compare(to rhs: _BigInt) -> _ComparisonResult { // Negative values are less than positive values @@ -1050,7 +1050,7 @@ public struct _BigInt : } } - /// Returns whether the magnitude of this instance is less than, greather + /// Returns whether the magnitude of this instance is less than, greater /// than, or equal to the magnitude of the given value. func _compareMagnitude(to rhs: _BigInt) -> _ComparisonResult { guard _data.count == rhs._data.count else { diff --git a/test/SIL/OwnershipVerifier/borrow_extract_validate.sil b/test/SIL/OwnershipVerifier/borrow_extract_validate.sil index f4f489ef62719..47609eb212d64 100644 --- a/test/SIL/OwnershipVerifier/borrow_extract_validate.sil +++ b/test/SIL/OwnershipVerifier/borrow_extract_validate.sil @@ -55,8 +55,8 @@ bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): return %ret : $() } -// CHECK-NOT: Function: 'borrowed_extract_dominate_discrepency_simple_correct' -sil [ossa] @borrowed_extract_dominate_discrepency_simple_correct : $@convention(thin) (@guaranteed WrapperStruct) -> () { +// CHECK-NOT: Function: 'borrowed_extract_dominate_discrepancy_simple_correct' +sil [ossa] @borrowed_extract_dominate_discrepancy_simple_correct : $@convention(thin) (@guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct): %elem = struct_extract %0 : $WrapperStruct, #WrapperStruct.cls br bb1(%elem : $Klass) @@ -77,14 +77,14 @@ bb1(%newelem : @guaranteed $Klass): return %res : $() } -// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrowed_extract_dominate_discrepency_incorrect1' +// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrowed_extract_dominate_discrepancy_incorrect1' // CHECK: Found outside of lifetime use?! // CHECK: Value: %7 = argument of bb1 : $WrapperStruct // CHECK: Consuming User: end_borrow %7 : $WrapperStruct // CHECK: Non Consuming User: %10 = apply %9(%6) : $@convention(thin) (@guaranteed Klass) -> () // CHECK: Block: bb1 -// CHECK-LABEL: Error#: 0. End Error in Function: 'borrowed_extract_dominate_discrepency_incorrect1' -sil [ossa] @borrowed_extract_dominate_discrepency_incorrect1 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +// CHECK-LABEL: Error#: 0. End Error in Function: 'borrowed_extract_dominate_discrepancy_incorrect1' +sil [ossa] @borrowed_extract_dominate_discrepancy_incorrect1 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): %copy0 = copy_value %0 : $WrapperStruct %borrow0 = begin_borrow %copy0 : $WrapperStruct @@ -100,15 +100,15 @@ bb1(%elem : @guaranteed $Klass, %newborrow : @guaranteed $WrapperStruct): return %ret : $() } -// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrowed_extract_dominate_discrepency_incorrect2' +// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrowed_extract_dominate_discrepancy_incorrect2' // CHECK: Found outside of lifetime use?! // CHECK: Value: %2 = copy_value %0 : $WrapperStruct // CHECK: Consuming User: destroy_value %2 : $WrapperStruct // CHECK: Non Consuming User: end_borrow %7 : $WrapperStruct // CHECK: Block: bb1 -// CHECK-LABEL: Error#: 0. End Error in Function: 'borrowed_extract_dominate_discrepency_incorrect2' -// CHECK-NOT: Error#: {{[0-9][0-9]*}}. End Error in Function: 'borrowed_extract_dominate_discrepency_incorrect2' -sil [ossa] @borrowed_extract_dominate_discrepency_incorrect2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +// CHECK-LABEL: Error#: 0. End Error in Function: 'borrowed_extract_dominate_discrepancy_incorrect2' +// CHECK-NOT: Error#: {{[0-9][0-9]*}}. End Error in Function: 'borrowed_extract_dominate_discrepancy_incorrect2' +sil [ossa] @borrowed_extract_dominate_discrepancy_incorrect2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): %copy0 = copy_value %0 : $WrapperStruct %borrow0 = begin_borrow %copy0 : $WrapperStruct diff --git a/test/SIL/OwnershipVerifier/borrow_validate.sil b/test/SIL/OwnershipVerifier/borrow_validate.sil index 04496e3e8a44c..9f3eecd841b71 100644 --- a/test/SIL/OwnershipVerifier/borrow_validate.sil +++ b/test/SIL/OwnershipVerifier/borrow_validate.sil @@ -239,8 +239,8 @@ bb3(%newborrow : @guaranteed $WrapperStruct, %newowned : @owned $WrapperStruct): return %ret : $() } -// CHECK-NOT: Function: 'borrow_lifetime_discrepency' -sil [ossa] @borrow_lifetime_discrepency : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +// CHECK-NOT: Function: 'borrow_lifetime_discrepancy' +sil [ossa] @borrow_lifetime_discrepancy : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): %copy0 = copy_value %0 : $WrapperStruct cond_br undef, bb1, bb2 @@ -263,8 +263,8 @@ bb3(%newborrowi : @guaranteed $WrapperStruct, %newborrowo : @guaranteed $Wrapper return %ret : $() } -// CHECK-NOT: Function: 'borrow_lifetime_discrepency_2' -sil [ossa] @borrow_lifetime_discrepency_2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +// CHECK-NOT: Function: 'borrow_lifetime_discrepancy_2' +sil [ossa] @borrow_lifetime_discrepancy_2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): cond_br undef, bb1, bb2 @@ -288,15 +288,15 @@ bb3(%newborrowi : @guaranteed $WrapperStruct, %newborrowo : @guaranteed $Wrapper return %ret : $() } -// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrow_lifetime_discrepency_incorrect_1' +// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrow_lifetime_discrepancy_incorrect_1' // CHECK: Found outside of lifetime use?! // CHECK: Value: %13 = argument of bb3 : $WrapperStruct // user: %15 // CHECK: Consuming User: destroy_value %13 : $WrapperStruct // id: %15 // CHECK: Non Consuming User: end_borrow %12 : $WrapperStruct // id: %16 // CHECK: Block: bb3 -// CHECK-LABEL: Error#: 0. End Error in Function: 'borrow_lifetime_discrepency_incorrect_1' +// CHECK-LABEL: Error#: 0. End Error in Function: 'borrow_lifetime_discrepancy_incorrect_1' // CHECK-NOT: Error#: 1. -sil [ossa] @borrow_lifetime_discrepency_incorrect_1 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +sil [ossa] @borrow_lifetime_discrepancy_incorrect_1 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): cond_br undef, bb1, bb2 @@ -320,15 +320,15 @@ bb3(%newborrowi : @guaranteed $WrapperStruct, %newborrowo : @guaranteed $Wrapper return %ret : $() } -// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrow_lifetime_discrepency_incorrect_2' +// CHECK-LABEL: Error#: 0. Begin Error in Function: 'borrow_lifetime_discrepancy_incorrect_2' // CHECK: Found outside of lifetime use?! // CHECK: Value: %12 = argument of bb3 : $WrapperStruct // user: %14 // CHECK: Consuming User: end_borrow %12 : $WrapperStruct // id: %14 // CHECK: Non Consuming User: end_borrow %11 : $WrapperStruct // id: %15 // CHECK: Block: bb3 -// CHECK-LABEL: Error#: 0. End Error in Function: 'borrow_lifetime_discrepency_incorrect_2' +// CHECK-LABEL: Error#: 0. End Error in Function: 'borrow_lifetime_discrepancy_incorrect_2' // CHECK-NOT: Error#: 1. -sil [ossa] @borrow_lifetime_discrepency_incorrect_2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { +sil [ossa] @borrow_lifetime_discrepancy_incorrect_2 : $@convention(thin) (@guaranteed WrapperStruct, @guaranteed WrapperStruct) -> () { bb0(%0 : @guaranteed $WrapperStruct, %1 : @guaranteed $WrapperStruct): cond_br undef, bb1, bb2 diff --git a/test/SIL/Serialization/public_external.sil b/test/SIL/Serialization/public_external.sil index 32d6a22f1cc6c..d572022977abf 100644 --- a/test/SIL/Serialization/public_external.sil +++ b/test/SIL/Serialization/public_external.sil @@ -40,7 +40,7 @@ sil hidden @he : $@convention(thin) () -> () { return %0 : $() } -sil hidden [transparent] @tranparent_he : $@convention(thin) () -> () { +sil hidden [transparent] @transparent_he : $@convention(thin) () -> () { %0 = tuple() return %0 : $() } diff --git a/test/SPI/accidental-reexport.swift b/test/SPI/accidental-reexport.swift index f7fe43bda198d..15b9dd9fe5f40 100644 --- a/test/SPI/accidental-reexport.swift +++ b/test/SPI/accidental-reexport.swift @@ -4,13 +4,13 @@ // RUN: %empty-directory(%t) // RUN: split-file %s %t -// RUN: %target-swift-frontend -emit-module %t/Overlayed.swift -I %t -o %t +// RUN: %target-swift-frontend -emit-module %t/Overlaid.swift -I %t -o %t // RUN: %target-swift-frontend -typecheck -verify %t/Client.swift -I %t // RUN: %target-swift-frontend -typecheck -verify %t/LowerClient.swift -I %t //--- module.modulemap -module Overlayed { - header "Overlayed.h" +module Overlaid { + header "Overlaid.h" } module Middle { @@ -23,9 +23,9 @@ module LowerMiddle { export * } -//--- Overlayed.h -//--- Overlayed.swift -@_exported import Overlayed +//--- Overlaid.h +//--- Overlaid.swift +@_exported import Overlaid public func funcPublic() {} @@ -33,7 +33,7 @@ public func funcPublic() {} public func funcSPI() {} //--- Middle.h -#include +#include //--- LowerMiddle.h #include diff --git a/test/ScanDependencies/optional_deps_of_binary_testable_imports.swift b/test/ScanDependencies/optional_deps_of_binary_testable_imports.swift index f3642cf19c8aa..0eda73f58e543 100644 --- a/test/ScanDependencies/optional_deps_of_binary_testable_imports.swift +++ b/test/ScanDependencies/optional_deps_of_binary_testable_imports.swift @@ -16,6 +16,6 @@ // The dependency of `Foo` on `A` will not be visible if the scanner simply scans the textual interface // of `Foo`. So we verify that for a `@testable` import, the scanner also opens up the adjacent binary module and -// attemtps to resolve optional dependencies contained within. +// attempts to resolve optional dependencies contained within. // // CHECK: "swift": "A" diff --git a/test/ScanDependencies/optional_deps_of_testable_imports.swift b/test/ScanDependencies/optional_deps_of_testable_imports.swift index 2851b9200ed34..98c331f0e3b2c 100644 --- a/test/ScanDependencies/optional_deps_of_testable_imports.swift +++ b/test/ScanDependencies/optional_deps_of_testable_imports.swift @@ -16,6 +16,6 @@ // The dependency of `Foo` on `A` will not be visible if the scanner simply scans the textual interface // of `Foo`. So we verify that for a `@testable` import, the scanner also opens up the adjacent binary module and -// attemtps to resolve optional dependencies contained within. +// attempts to resolve optional dependencies contained within. // // CHECK: "swift": "A" diff --git a/test/ScanDependencies/optional_transitive_dep_load_fail.swift b/test/ScanDependencies/optional_transitive_dep_load_fail.swift index 6b5ccbb2df19a..698ae416944e9 100644 --- a/test/ScanDependencies/optional_transitive_dep_load_fail.swift +++ b/test/ScanDependencies/optional_transitive_dep_load_fail.swift @@ -37,7 +37,7 @@ // Step 1: build Foo Swift module // RUN: %target-swift-frontend -emit-module %t/Foo.swift -emit-module-path %t/Foo.swiftmodule/%target-swiftmodule-name -module-name Foo -emit-module-interface-path %t/Foo.swiftmodule/%target-swiftinterface-name -enable-library-evolution -I %S/Inputs/CHeaders -I %S/Inputs/Swift -enable-testing -swift-version 5 -disable-implicit-concurrency-module-import -disable-implicit-string-processing-module-import -// Step 2: scan dependencies and ensure the transitive dependency on "A" is misssing +// Step 2: scan dependencies and ensure the transitive dependency on "A" is missing // RUN: %target-swift-frontend -scan-dependencies %s -o %t/deps.json -I %t -sdk %t -prebuilt-module-cache-path %t/clang-module-cache // RUN: %validate-json %t/deps.json | %FileCheck -check-prefix CHECK_SCAN %s // CHECK_SCAN-NOT: "swift": "A" diff --git a/test/Sema/accessibility.swift b/test/Sema/accessibility.swift index a766532be8c1b..09da58614c689 100644 --- a/test/Sema/accessibility.swift +++ b/test/Sema/accessibility.swift @@ -955,7 +955,7 @@ package enum PackageGenericEnumT { // expected-error {{generic case A } -/// Test setters with less accss level +/// Test setters with less access level public protocol PublicMutationOperations { var size: Int { get set } subscript (_: Int) -> Int { get set } @@ -1482,19 +1482,19 @@ public class DerivedFromInternalConcreteGenericCompositionPkg : InternalConcrete } package typealias PackageConcreteGenericComposition = PublicGenericClass & PublicProto // expected-note {{declared here}} -public class DerivedFromPacakgeConcreteGenericComposition : PackageConcreteGenericComposition { // expected-error {{class cannot be declared public because its superclass is package}} +public class DerivedFromPackageConcreteGenericComposition : PackageConcreteGenericComposition { // expected-error {{class cannot be declared public because its superclass is package}} public func publicReq() {} } package typealias PackageConcreteGenericCompositionStr = PackageGenericClass & PackageProto // expected-note {{declared here}} -public class DerivedFromPacakgeConcreteGenericComposition2 : PackageConcreteGenericCompositionStr { // expected-error {{class cannot be declared public because its superclass is package}} +public class DerivedFromPackageConcreteGenericComposition2 : PackageConcreteGenericCompositionStr { // expected-error {{class cannot be declared public because its superclass is package}} public func packageReq() {} } -package class DerivedFromPacakgeConcreteGenericComposition3 : PackageConcreteGenericCompositionStr { // no-warning +package class DerivedFromPackageConcreteGenericComposition3 : PackageConcreteGenericCompositionStr { // no-warning public func packageReq() {} } -internal class DerivedFromPacakgeConcreteGenericComposition4 : PackageConcreteGenericCompositionStr { // no-warning +internal class DerivedFromPackageConcreteGenericComposition4 : PackageConcreteGenericCompositionStr { // no-warning public func packageReq() {} } diff --git a/test/Sema/availability_versions.swift b/test/Sema/availability_versions.swift index 79cbbad4a4cf4..2fee710cf85c5 100644 --- a/test/Sema/availability_versions.swift +++ b/test/Sema/availability_versions.swift @@ -841,7 +841,7 @@ class SubWithLimitedMemberAvailability : SuperWithAlwaysAvailableMembers { } @available(OSX, introduced: 10.51) -class SubWithLimitedAvailablility : SuperWithAlwaysAvailableMembers { +class SubWithLimitedAvailability : SuperWithAlwaysAvailableMembers { override func shouldAlwaysBeAvailableMethod() {} override var shouldAlwaysBeAvailableProperty: Int { diff --git a/test/Sema/availability_versions_objc_api.swift b/test/Sema/availability_versions_objc_api.swift index 777573c19a014..18ee8cbc5f891 100644 --- a/test/Sema/availability_versions_objc_api.swift +++ b/test/Sema/availability_versions_objc_api.swift @@ -40,7 +40,7 @@ func functionWithObjCParam(o: NSAvailableOn10_51) { // expected-error {{'NSAvail // expected-note@-1 {{add @available attribute to enclosing global function}} } -class ClassExtendingUnvailableClass : NSAvailableOn10_51 { // expected-error {{'NSAvailableOn10_51' is only available in macOS 10.51 or newer}} +class ClassExtendingUnavailableClass : NSAvailableOn10_51 { // expected-error {{'NSAvailableOn10_51' is only available in macOS 10.51 or newer}} // expected-note@-1 {{add @available attribute to enclosing class}} } diff --git a/test/Sema/diag_constantness_check.swift b/test/Sema/diag_constantness_check.swift index 07a01074c9e9d..7f9a621e392a2 100644 --- a/test/Sema/diag_constantness_check.swift +++ b/test/Sema/diag_constantness_check.swift @@ -198,7 +198,7 @@ func testConstantArgumentWithConstEval(constParam: Int) { constantArgumentFunction(constantEval(constParam, true)) } -// Test parital-apply of constantArgumentFunction. +// Test partial-apply of constantArgumentFunction. @_semantics("oslog.requires_constant_arguments") func constArg2(_ x: Int) -> Int { x } diff --git a/test/Sema/superfluously-public-imports.swift b/test/Sema/superfluously-public-imports.swift index b6e7f137c475d..299c75f7db2b2 100644 --- a/test/Sema/superfluously-public-imports.swift +++ b/test/Sema/superfluously-public-imports.swift @@ -271,7 +271,7 @@ module ClangSubmodule { module ClangSubmoduleUnused { header "ClangSubmoduleUnused.h" - module ClangSubmoduleUnsuedSubmodule { + module ClangSubmoduleUnusedSubmodule { header "ClangSubmoduleUnusedSubmodule.h" } } @@ -302,7 +302,7 @@ struct ClangTopModuleType {}; public import ClangSimple public import ClangSimpleUnused // expected-warning {{public import of 'ClangSimpleUnused' was not used in public declarations or inlinable code}} public import ClangSubmodule.ClangSubmoduleSubmodule -public import ClangSubmoduleUnused.ClangSubmoduleUnsuedSubmodule // expected-warning {{public import of 'ClangSubmoduleUnused' was not used in public declarations or inlinable code}} +public import ClangSubmoduleUnused.ClangSubmoduleUnusedSubmodule // expected-warning {{public import of 'ClangSubmoduleUnused' was not used in public declarations or inlinable code}} // Only the top-level module is used, but we can't detect whether the submodule was used or not. public import ClangTopModule.ClangTopModuleSubmodule diff --git a/test/attr/attr_availability_narrow.swift b/test/attr/attr_availability_narrow.swift index a70fa90a76656..9a534c99f856a 100644 --- a/test/attr/attr_availability_narrow.swift +++ b/test/attr/attr_availability_narrow.swift @@ -1,6 +1,6 @@ // RUN: %target-typecheck-verify-swift // REQUIRES: OS=macosx -// Suggest narrowing the range of bad availabile checks +// Suggest narrowing the range of bad available checks import Foundation diff --git a/test/decl/var/init_accessors.swift b/test/decl/var/init_accessors.swift index b280fe089c624..560ab6a63940a 100644 --- a/test/decl/var/init_accessors.swift +++ b/test/decl/var/init_accessors.swift @@ -446,7 +446,7 @@ func test_memberwise_ordering() { var pair: (Int, Int) { @storageRestrictions(accesses: _a, _b) - init(initalValue) { + init(initialValue) { } get { (_a, _b) } @@ -464,7 +464,7 @@ func test_memberwise_ordering() { var c: Int { @storageRestrictions(initializes: _c, accesses: _a, _b) - init(initalValue) { + init(initialValue) { } get { _c } @@ -494,7 +494,7 @@ func test_default_arguments_are_analyzed() { var otherPair = (0, 1) { // expected-error@-1 {{computed property must have an explicit type}} - init(initalValue) {} + init(initialValue) {} get { 42 } // expected-error@-1 {{cannot convert return expression of type 'Int' to return type '(Int, Int)'}} diff --git a/test/embedded/FixedArray.swift b/test/embedded/FixedArray.swift index ffb8c051b7167..c61a6f287a78f 100644 --- a/test/embedded/FixedArray.swift +++ b/test/embedded/FixedArray.swift @@ -28,7 +28,7 @@ func testDestroyOfElements() { a.append(CheckLifetime(29)) a.append(CheckLifetime(30)) - // The `*` is a prefix operator and serves as syntatic sugar for FixedArray.view. + // The `*` is a prefix operator and serves as syntactic sugar for FixedArray.view. printit(*a) } @@ -58,7 +58,7 @@ struct S { static var a = FixedArray(capacity: 10) // Elements are initialized in the data section. - // The `^` is a prefix operator and serves as syntatic sugar to create a FixedArray literal. + // The `^` is a prefix operator and serves as syntactic sugar to create a FixedArray literal. static let b = ^[1, 2, 3] static let c: FixedArray = ^[10, 20, 30] diff --git a/test/embedded/Inputs/ExperimentalFixedArray.swift b/test/embedded/Inputs/ExperimentalFixedArray.swift index bd5809fa0d500..2a1b0dceb9d8a 100644 --- a/test/embedded/Inputs/ExperimentalFixedArray.swift +++ b/test/embedded/Inputs/ExperimentalFixedArray.swift @@ -93,7 +93,7 @@ public struct FixedArray : ~Copyable { } } -// Syntatic sugar for creating a FixedArray literal +// Syntactic sugar for creating a FixedArray literal prefix operator ^ @_transparent @@ -102,7 +102,7 @@ public prefix func ^(_ literal: FixedArray._Literal) -> FixedArray { return FixedArray(elements: literal.array) } -// Syntatic sugar for getting a BufferView to a FixedArray +// Syntactic sugar for getting a BufferView to a FixedArray prefix operator * @_transparent diff --git a/test/embedded/ouroboros-bug.swift b/test/embedded/ouroboros-bug.swift index cbbddbdac512f..d009421351f5f 100644 --- a/test/embedded/ouroboros-bug.swift +++ b/test/embedded/ouroboros-bug.swift @@ -1,5 +1,5 @@ // Regression test for a "Ouroboros Bug": The ARC optimizer doesn't like the -// presense of a direct call to swift_retain and swift_release in any Swift +// presence of a direct call to swift_retain and swift_release in any Swift // code, but in the embedded Swift's runtime that's somewhat reasonable thing // to do (but is to be avoided because of this). diff --git a/test/expr/unary/if_expr.swift b/test/expr/unary/if_expr.swift index 93ab2969efd2f..5f487efe8b2de 100644 --- a/test/expr/unary/if_expr.swift +++ b/test/expr/unary/if_expr.swift @@ -383,7 +383,7 @@ func throwsError() throws { } // FIXME: If we ever support this, we need to fix the premature inference of '[Any]'/'[AnyHashable: Any]'. -// The issue is that we're attempting to bind defaults to type variables before solving the conjuction. +// The issue is that we're attempting to bind defaults to type variables before solving the conjunction. let g = [if .random() { "a" } else { "b" }] // expected-error@-1 {{'if' may only be used as expression in return, throw, or as the source of an assignment}} // expected-error@-2 {{heterogeneous collection literal could only be inferred to '[Any]'; add explicit type annotation if this is intentional}} @@ -850,7 +850,7 @@ func testPoundIfBranch4() -> Int { } func testPoundIfBranch5() -> Int { - // Not allowed (matches the behavior of implict expression returns) + // Not allowed (matches the behavior of implicit expression returns) if .random() { #if false 0 @@ -862,7 +862,7 @@ func testPoundIfBranch5() -> Int { } func testPoundIfBranch6() -> Int { - // Not allowed (matches the behavior of implict expression returns) + // Not allowed (matches the behavior of implicit expression returns) let x = if .random() { #if false 0 diff --git a/test/expr/unary/switch_expr.swift b/test/expr/unary/switch_expr.swift index cf161341a3556..5181c83331a98 100644 --- a/test/expr/unary/switch_expr.swift +++ b/test/expr/unary/switch_expr.swift @@ -458,7 +458,7 @@ func throwsError() throws { } // FIXME: If we ever support this, we need to fix the premature inference of '[Any]'/'[AnyHashable: Any]'. -// The issue is that we're attempting to bind defaults to type variables before solving the conjuction. +// The issue is that we're attempting to bind defaults to type variables before solving the conjunction. let g = [switch Bool.random() { case true: "a" case false: "b" }] // expected-error@-1 {{'switch' may only be used as expression in return, throw, or as the source of an assignment}} // expected-error@-2 {{heterogeneous collection literal could only be inferred to '[Any]'; add explicit type annotation if this is intentional}} @@ -1078,7 +1078,7 @@ func testPoundIfBranch4() -> Int { } func testPoundIfBranch5() -> Int { - // Not allowed (matches the behavior of implict expression returns) + // Not allowed (matches the behavior of implicit expression returns) switch Bool.random() { case true: #if false @@ -1091,7 +1091,7 @@ func testPoundIfBranch5() -> Int { } func testPoundIfBranch6() -> Int { - // Not allowed (matches the behavior of implict expression returns) + // Not allowed (matches the behavior of implicit expression returns) let x = switch Bool.random() { case true: #if false diff --git a/test/lit.cfg b/test/lit.cfg index bac9668efe196..8e464eb0a1bad 100644 --- a/test/lit.cfg +++ b/test/lit.cfg @@ -399,7 +399,7 @@ if kIsWindows: config.swift_system_overlay_opt = "-vfsoverlay {} -strict-implicit-module-context -Xcc -Xclang -Xcc -fbuiltin-headers-in-system-modules".format( os.path.join(config.swift_obj_root, "stdlib", "windows-vfs-overlay.yaml") ) - # this variant is for extract-symbolgraph which doesn't accept all the same arugments as swiftc + # this variant is for extract-symbolgraph which doesn't accept all the same arguments as swiftc # so the extra ceremony lets us pass in the relevant pieces needed for Windows SDK access. config.windows_vfs_overlay_opt = "-Xcc -vfsoverlay -Xcc {} -Xcc -strict-implicit-module-context -Xcc -Xclang -Xcc -fbuiltin-headers-in-system-modules".format( os.path.join(config.swift_obj_root, "stdlib", "windows-vfs-overlay.yaml") @@ -597,7 +597,7 @@ lit_config.note("Using code completion cache: " + completion_cache_path) if kIsWindows: config.swift_plugin_dir = config.swift_bin_dir - # FIXME: this is a workaround for the collsion between the build toolchain + # FIXME: this is a workaround for the collision between the build toolchain # and the current build, this should be `make_path(config.swift_lib_dir, 'swift')` config.swift_build_lib_dir = make_path(config.swift_lib_dir, 'swift', 'host') else: @@ -2876,7 +2876,7 @@ config.substitutions.append(('%raw-FileCheck', shell_quote(config.filecheck))) config.substitutions.append(('%import-libdispatch', getattr(config, 'import_libdispatch', ''))) # WARNING: the order of components in a substitution name has to be different from the previous one, as lit does # a pure string substitution without understanding that these components are grouped together. That is, the following -# subsitution name can't be `%import-libdispatch-static`, otherwise the first two components will be substituted with +# substitution name can't be `%import-libdispatch-static`, otherwise the first two components will be substituted with # the value of `%import-libdispatch` substitution with `-static` string appended to it. config.substitutions.append(('%import-static-libdispatch', getattr(config, 'import_libdispatch_static', ''))) diff --git a/test/refactoring/RefactoringKind/simplify_long_number.swift b/test/refactoring/RefactoringKind/simplify_long_number.swift index 722b4fffad706..125c655e9ad56 100644 --- a/test/refactoring/RefactoringKind/simplify_long_number.swift +++ b/test/refactoring/RefactoringKind/simplify_long_number.swift @@ -11,16 +11,16 @@ func foo() { _ = 123.123 } -// RUN: %refactor -source-filename %s -pos=4:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMER -// RUN: %refactor -source-filename %s -pos=5:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMER -// RUN: %refactor -source-filename %s -pos=6:15 | %FileCheck %s -check-prefix=CHECK-LONG-NUMER -// RUN: %refactor -source-filename %s -pos=7:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMER -// RUN: %refactor -source-filename %s -pos=8:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMER +// RUN: %refactor -source-filename %s -pos=4:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMBER +// RUN: %refactor -source-filename %s -pos=5:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMBER +// RUN: %refactor -source-filename %s -pos=6:15 | %FileCheck %s -check-prefix=CHECK-LONG-NUMBER +// RUN: %refactor -source-filename %s -pos=7:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMBER +// RUN: %refactor -source-filename %s -pos=8:10 | %FileCheck %s -check-prefix=CHECK-LONG-NUMBER // RUN: %refactor -source-filename %s -pos=10:8 | %FileCheck %s -check-prefix=CHECK-NONE // RUN: %refactor -source-filename %s -pos=11:8 | %FileCheck %s -check-prefix=CHECK-NONE -// CHECK-LONG-NUMER: Simplify Long Number Literal +// CHECK-LONG-NUMBER: Simplify Long Number Literal // CHECK-NONE: Action begins // CHECK-NONE-NEXT: Action ends diff --git a/test/refactoring/SyntacticRename/Outputs/textual/foo.swift.expected b/test/refactoring/SyntacticRename/Outputs/textual/foo.swift.expected index 0e4464b6ebf50..8ec14f8f52f9a 100644 --- a/test/refactoring/SyntacticRename/Outputs/textual/foo.swift.expected +++ b/test/refactoring/SyntacticRename/Outputs/textual/foo.swift.expected @@ -36,4 +36,4 @@ _ = /*MyClass:unknown*/Mismatch() _ = /*MyClass:unknown*/MyClass() #endif -// All occcurrences of MyClass are outside of comments and string literals, so there's nothing to rename. swift-refactor indicates this by outputing empty results. +// All occcurrences of MyClass are outside of comments and string literals, so there's nothing to rename. swift-refactor indicates this by outputting empty results. diff --git a/test/refactoring/SyntacticRename/textual.swift b/test/refactoring/SyntacticRename/textual.swift index 7a7cd7445756c..4257030ca4b6d 100644 --- a/test/refactoring/SyntacticRename/textual.swift +++ b/test/refactoring/SyntacticRename/textual.swift @@ -41,5 +41,5 @@ _ = /*MyClass:unknown*/MyClass() // RUN: %refactor -find-rename-ranges -source-filename %s -pos="foo" -is-function-like -old-name "foo()" >> %t.ranges/textual_foo.swift // RUN: diff -u %S/Outputs/textual/foo.swift.expected %t.ranges/textual_foo.swift // RUN: %refactor -find-rename-ranges -source-filename %s -pos="MyClass" -is-non-protocol-type -old-name "MyClass" -new-name "YourClass" >> %t.ranges/textual_MyClass.swift -// All occcurrences of MyClass are outside of comments and string literals, so there's nothing to rename. swift-refactor indicates this by outputing empty results. +// All occcurrences of MyClass are outside of comments and string literals, so there's nothing to rename. swift-refactor indicates this by outputting empty results. // RUN: diff -u %t.ranges/textual_MyClass.swift - diff --git a/test/stdlib/SwiftObjectNSObject.swift b/test/stdlib/SwiftObjectNSObject.swift index 084de337343b4..d5f4cda6776a7 100644 --- a/test/stdlib/SwiftObjectNSObject.swift +++ b/test/stdlib/SwiftObjectNSObject.swift @@ -245,7 +245,7 @@ if #available(OSX 10.12, iOS 10.0, *) { TestNonEquatableEquals(F1(i: 1), E(i: 1)) TestEquatableEquals(H(i:1), E(i:1)) - // Equatable but not Hashable: alway have the same Obj-C hashValue + // Equatable but not Hashable: always have the same Obj-C hashValue TestEquatableHash(E(i: 1)) TestEquatableHash(E1(i: 3)) TestEquatableHash(E2(i: 8)) diff --git a/test/stdlib/SwiftValueNSObject.swift b/test/stdlib/SwiftValueNSObject.swift index 3ac6695cffa37..5013ad3b4e74c 100644 --- a/test/stdlib/SwiftValueNSObject.swift +++ b/test/stdlib/SwiftValueNSObject.swift @@ -140,7 +140,7 @@ if #available(OSX 10.12, iOS 10.0, *) { TestNonEquatableEquals(F(i: 1), F(i: 1)) TestSwiftValueNSObjectNotEquals(H(i:1) as AnyObject, E(i:1) as AnyObject) - // Equatable but not Hashable: alway have the same Obj-C hashValue + // Equatable but not Hashable: always have the same Obj-C hashValue TestEquatableHash(E(i: 1)) TestEquatableHash(E1(i: 17))