@@ -572,12 +572,12 @@ NOTE(async_inferred_from_operation,none,
572
572
// Key-path expressions.
573
573
ERROR(expr_keypath_no_objc_runtime,none,
574
574
" '#keyPath' can only be used with the Objective-C runtime" , ())
575
- ERROR(expression_unused_keypath_result,none ,
575
+ ERROR(expression_unused_keypath_result,NoUsage ,
576
576
" result of key path is unused" , ())
577
577
ERROR(expr_keypath_non_objc_property,none,
578
578
" argument of '#keyPath' refers to non-'@objc' property %0" ,
579
579
(Identifier))
580
- WARNING(expr_keypath_swift3_objc_inference,none ,
580
+ WARNING(expr_keypath_swift3_objc_inference,Deprecation ,
581
581
" argument of '#keyPath' refers to property %0 in %1 that depends on "
582
582
" '@objc' inference deprecated in Swift 4" ,
583
583
(Identifier, Identifier))
@@ -637,7 +637,7 @@ ERROR(expr_swift_keypath_anyobject_root,none,
637
637
" the root type of a Swift key path cannot be 'AnyObject'" , ())
638
638
ERROR(expr_keypath_multiparam_func_conversion, none,
639
639
" cannot convert key path into a multi-argument function type %0" , (Type))
640
- WARNING(expr_deprecated_writable_keypath,none ,
640
+ WARNING(expr_deprecated_writable_keypath,Deprecation ,
641
641
" forming a writable keypath to property %0 that is read-only in this context "
642
642
" is deprecated and will be removed in a future release" ,(DeclName))
643
643
@@ -680,7 +680,7 @@ ERROR(expr_selector_not_objc,none,
680
680
NOTE(make_decl_objc,none,
681
681
" add '@objc' to expose this %0 to Objective-C" ,
682
682
(DescriptiveDeclKind))
683
- WARNING(expr_selector_swift3_objc_inference,none ,
683
+ WARNING(expr_selector_swift3_objc_inference,Deprecation ,
684
684
" argument of '#selector' refers to %0 %1 in %2 that depends on "
685
685
" '@objc' inference deprecated in Swift 4" ,
686
686
(DescriptiveDeclKind, DeclName, Identifier))
@@ -690,10 +690,10 @@ WARNING(selector_literal_invalid,none,
690
690
" string literal is not a valid Objective-C selector" , ())
691
691
WARNING(selector_literal_undeclared,none,
692
692
" no method declared with Objective-C selector %0" , (ObjCSelector))
693
- WARNING(selector_literal_deprecated,none ,
693
+ WARNING(selector_literal_deprecated,Deprecation ,
694
694
" use of string literal for Objective-C selectors is deprecated; "
695
695
" use '#selector' or explicitly construct a 'Selector'" , ())
696
- WARNING(selector_literal_deprecated_suggest,none ,
696
+ WARNING(selector_literal_deprecated_suggest,Deprecation ,
697
697
" use of string literal for Objective-C selectors is deprecated; "
698
698
" use '#selector' instead" , ())
699
699
WARNING(selector_construction_suggest,none,
@@ -828,7 +828,7 @@ ERROR(invalid_redecl_implicit,none,
828
828
" invalid redeclaration of synthesized "
829
829
" %select{%0|implementation for protocol requirement}1 %2" ,
830
830
(DescriptiveDeclKind, bool , DeclName))
831
- WARNING(invalid_redecl_swift5_warning,none ,
831
+ WARNING(invalid_redecl_swift5_warning,Deprecation ,
832
832
" redeclaration of %0 is deprecated and will be an error in Swift 5" ,
833
833
(DeclName))
834
834
@@ -1271,7 +1271,7 @@ ERROR(extra_trailing_closure_in_call,none,
1271
1271
ERROR(trailing_closure_bad_param,none,
1272
1272
" trailing closure passed to parameter of type %0 that does not "
1273
1273
" accept a closure" , (Type))
1274
- WARNING(unlabeled_trailing_closure_deprecated,none ,
1274
+ WARNING(unlabeled_trailing_closure_deprecated,Deprecation ,
1275
1275
" backward matching of the unlabeled trailing closure is deprecated; label the argument with %0 to suppress this warning" ,
1276
1276
(Identifier))
1277
1277
NOTE(decl_multiple_defaulted_closure_parameters,none,
@@ -1551,7 +1551,7 @@ ERROR(missing_unimplemented_init_runtime,none,
1551
1551
ERROR(missing_undefined_runtime,none,
1552
1552
" standard library error: missing _undefined" , ())
1553
1553
1554
- WARNING(expr_dynamic_lookup_swift3_objc_inference,none ,
1554
+ WARNING(expr_dynamic_lookup_swift3_objc_inference,Deprecation ,
1555
1555
" reference to %0 %1 of %2 depends on '@objc' inference "
1556
1556
" deprecated in Swift 4" ,
1557
1557
(DescriptiveDeclKind, DeclName, Identifier))
@@ -2676,7 +2676,7 @@ WARNING(implicitly_final_cannot_be_open_swift4,none,
2676
2676
" static declarations}0 are implicitly 'final'; use 'public' instead of "
2677
2677
" 'open'" , (unsigned ))
2678
2678
2679
- WARNING(override_swift3_objc_inference,none ,
2679
+ WARNING(override_swift3_objc_inference,Deprecation ,
2680
2680
" override of %0 %1 from extension of %2 depends on deprecated "
2681
2681
" inference of '@objc'" ,
2682
2682
(DescriptiveDeclKind, DeclName, Identifier))
@@ -2692,7 +2692,7 @@ WARNING(duplicate_anyobject_class_inheritance,none,
2692
2692
" redundant inheritance from 'AnyObject' and Swift 3 'class' keyword" , ())
2693
2693
ERROR(inheritance_from_protocol_with_superclass,none,
2694
2694
" inheritance from class-constrained protocol composition type %0" , (Type))
2695
- WARNING(anyobject_class_inheritance_deprecated,none ,
2695
+ WARNING(anyobject_class_inheritance_deprecated,Deprecation ,
2696
2696
" using 'class' keyword to define a class-constrained protocol is deprecated; "
2697
2697
" use 'AnyObject' instead" , ())
2698
2698
ERROR(multiple_inheritance,none,
@@ -3756,12 +3756,12 @@ NOTE(fix_unqualified_access_top_level_multi,none,
3756
3756
" use '%0' to reference the %1 in module %2" ,
3757
3757
(StringRef, DescriptiveDeclKind, Identifier))
3758
3758
3759
- WARNING(warn_deprecated_conditional_conformance_outer_access,none ,
3759
+ WARNING(warn_deprecated_conditional_conformance_outer_access,Deprecation ,
3760
3760
" use of %0 as reference to %1 in %2 %3 will change in future versions of Swift to reference %4 in %5 %6 "
3761
3761
" which comes via a conditional conformance" ,
3762
3762
(DeclNameRef, DescriptiveDeclKind, DescriptiveDeclKind, DeclName,
3763
3763
DescriptiveDeclKind, DescriptiveDeclKind, DeclName))
3764
- NOTE(fix_deprecated_conditional_conformance_outer_access,none ,
3764
+ NOTE(fix_deprecated_conditional_conformance_outer_access,Deprecation ,
3765
3765
" use '%0' to continue to reference the %1" ,
3766
3766
(StringRef, DescriptiveDeclKind, Identifier))
3767
3767
@@ -3816,7 +3816,7 @@ WARNING(bitcasting_to_change_from_unsized_to_sized_int, none,
3816
3816
" initializer" ,
3817
3817
(Type, Type))
3818
3818
3819
- WARNING(use_of_qq_on_non_optional_value,none ,
3819
+ WARNING(use_of_qq_on_non_optional_value,NoUsage ,
3820
3820
" left side of nil coalescing operator '?" " ?' has non-optional type %0, "
3821
3821
" so the right side is never used" , (Type))
3822
3822
WARNING(nonoptional_compare_to_nil,none,
@@ -3932,32 +3932,32 @@ WARNING(guard_always_succeeds,none,
3932
3932
" 'guard' condition is always true, body is unreachable" , ())
3933
3933
3934
3934
3935
- ERROR(expression_unused_closure,none ,
3935
+ ERROR(expression_unused_closure,NoUsage ,
3936
3936
" closure expression is unused" , ())
3937
- ERROR(expression_unused_function,none ,
3937
+ ERROR(expression_unused_function,NoUsage ,
3938
3938
" function is unused" , ())
3939
- WARNING(expression_unused_lvalue,none ,
3939
+ WARNING(expression_unused_lvalue,NoUsage ,
3940
3940
" %select{"
3941
3941
" variable|"
3942
3942
" property is accessed but result|"
3943
3943
" subscript is accessed but result"
3944
3944
" }0 is unused" ,
3945
3945
(unsigned ))
3946
- WARNING(expression_unused_result_call,none ,
3946
+ WARNING(expression_unused_result_call,NoUsage ,
3947
3947
" result of call to %0 is unused" , (DeclName))
3948
- WARNING(expression_unused_result_operator,none ,
3948
+ WARNING(expression_unused_result_operator,NoUsage ,
3949
3949
" result of operator %0 is unused" , (DeclName))
3950
- WARNING(expression_unused_result_unknown, none ,
3950
+ WARNING(expression_unused_result_unknown, NoUsage ,
3951
3951
" result of call to %select{function|closure}0 returning %1 is unused" , (bool , Type))
3952
- WARNING(expression_unused_result, none ,
3952
+ WARNING(expression_unused_result, NoUsage ,
3953
3953
" expression of type %0 is unused" , (Type))
3954
- WARNING(expression_unused_init_result,none ,
3954
+ WARNING(expression_unused_init_result,NoUsage ,
3955
3955
" result of %0 initializer is unused" , (Type))
3956
- WARNING(expression_unused_optional_try,none ,
3956
+ WARNING(expression_unused_optional_try,NoUsage ,
3957
3957
" result of 'try?' is unused" , ())
3958
- WARNING(expression_unused_selector_result, none ,
3958
+ WARNING(expression_unused_selector_result, NoUsage ,
3959
3959
" result of '#selector' is unused" , ())
3960
- WARNING(expression_unused_literal,none ,
3960
+ WARNING(expression_unused_literal,NoUsage ,
3961
3961
" %0 literal is unused" , (StringRef))
3962
3962
3963
3963
ERROR(assignment_lhs_not_lvalue,none,
@@ -4101,7 +4101,7 @@ ERROR(pattern_type_mismatch_context,none,
4101
4101
4102
4102
ERROR(tuple_pattern_in_non_tuple_context,none,
4103
4103
" tuple pattern cannot match values of the non-tuple type %0" , (Type))
4104
- WARNING(found_one_pattern_for_several_associated_values,none ,
4104
+ WARNING(found_one_pattern_for_several_associated_values,Deprecation ,
4105
4105
" enum case '%0' has %1 associated values; matching them as a tuple "
4106
4106
" is deprecated" , (StringRef, unsigned ))
4107
4107
WARNING(converting_tuple_into_several_associated_values,none,
@@ -4646,7 +4646,7 @@ ERROR(enum_element_ellipsis,none,
4646
4646
WARNING(implicitly_unwrapped_optional_in_illegal_position_interpreted_as_optional,none,
4647
4647
" using '!' is not allowed here; treating this as '?' instead" , ())
4648
4648
4649
- WARNING(implicitly_unwrapped_optional_deprecated_in_this_position,none ,
4649
+ WARNING(implicitly_unwrapped_optional_deprecated_in_this_position,Deprecation ,
4650
4650
" using '!' here is deprecated and will be removed in a future release" , ())
4651
4651
4652
4652
ERROR(implicitly_unwrapped_optional_in_illegal_position,none,
@@ -4710,7 +4710,7 @@ ERROR(attribute_requires_function_type,none,
4710
4710
" @%0 attribute only applies to function types" , (StringRef))
4711
4711
ERROR(unsupported_convention,none,
4712
4712
" convention '%0' not supported" , (StringRef))
4713
- ERROR(unreferenced_generic_parameter,none ,
4713
+ ERROR(unreferenced_generic_parameter,NoUsage ,
4714
4714
" generic parameter '%0' is not used in function signature" , (StringRef))
4715
4715
ERROR(unexpected_ctype_for_non_c_convention,none,
4716
4716
" convention '%0' does not support the 'cType' argument label, did you "
@@ -4825,9 +4825,9 @@ ERROR(objc_operator, none,
4825
4825
" operator methods cannot be declared @objc" , ())
4826
4826
ERROR(objc_operator_proto, none,
4827
4827
" @objc protocols must not have operator requirements" , ())
4828
- WARNING(objc_inference_swift3_dynamic,none ,
4828
+ WARNING(objc_inference_swift3_dynamic,Deprecation ,
4829
4829
" inference of '@objc' for 'dynamic' members is deprecated" , ())
4830
- WARNING(objc_inference_swift3_objc_derived,none ,
4830
+ WARNING(objc_inference_swift3_objc_derived,Deprecation ,
4831
4831
" inference of '@objc' for members of Objective-C-derived classes is "
4832
4832
" deprecated" , ())
4833
4833
@@ -4852,7 +4852,7 @@ ERROR(objc_setter_for_nonobjc_property,none,
4852
4852
" '@objc' setter for non-'@objc' property" , ())
4853
4853
ERROR(objc_setter_for_nonobjc_subscript,none,
4854
4854
" '@objc' setter for non-'@objc' subscript" , ())
4855
- WARNING(accessor_swift3_objc_inference,none ,
4855
+ WARNING(accessor_swift3_objc_inference,Deprecation ,
4856
4856
" %select{%0 %1|%1}2 with '@objc' %select{getter|setter}3 depends on "
4857
4857
" deprecated inference of '@objc'" ,
4858
4858
(DescriptiveDeclKind, DeclName, bool , bool ))
@@ -4947,7 +4947,7 @@ NOTE(objc_overriding_objc_decl,none,
4947
4947
NOTE(objc_witness_objc_requirement,none,
4948
4948
" satisfying requirement for %0 %1 in protocol %2" ,
4949
4949
(DescriptiveDeclKind, DeclName, Identifier))
4950
- WARNING(witness_swift3_objc_inference,none ,
4950
+ WARNING(witness_swift3_objc_inference,Deprecation ,
4951
4951
" use of %0 %1 to satisfy a requirement of protocol %2 depends on "
4952
4952
" '@objc' inference deprecated in Swift 4" ,
4953
4953
(DescriptiveDeclKind, DeclName, Type))
@@ -5229,13 +5229,13 @@ NOTE(availability_obsoleted, none,
5229
5229
" %select{getter for |setter for |}0%1 was obsoleted in %2 %3" ,
5230
5230
(unsigned , DeclName, StringRef, llvm::VersionTuple))
5231
5231
5232
- WARNING(availability_deprecated, none ,
5232
+ WARNING(availability_deprecated, Deprecation ,
5233
5233
" %select{getter for |setter for |}0%1 %select{is|%select{is|was}4}2 "
5234
5234
" deprecated%select{| in %3%select{| %5}4}2%select{|: %6}6" ,
5235
5235
(unsigned , DeclName, bool , StringRef, bool , llvm::VersionTuple,
5236
5236
StringRef))
5237
5237
5238
- WARNING(availability_deprecated_rename, none ,
5238
+ WARNING(availability_deprecated_rename, Deprecation ,
5239
5239
" %select{getter for |setter for |}0%1 %select{is|%select{is|was}4}2 "
5240
5240
" deprecated%select{| in %3%select{| %5}4}2: "
5241
5241
" %select{renamed to|replaced by}6%" REPLACEMENT_DECL_KIND_SELECT " 7 "
@@ -5244,7 +5244,7 @@ WARNING(availability_deprecated_rename, none,
5244
5244
unsigned , StringRef))
5245
5245
#undef REPLACEMENT_DECL_KIND_SELECT
5246
5246
5247
- NOTE (note_deprecated_rename, none ,
5247
+ NOTE (note_deprecated_rename, Deprecation ,
5248
5248
" use '%0' instead" , (StringRef))
5249
5249
5250
5250
ERROR(availability_decl_more_than_enclosing, none,
@@ -5347,7 +5347,7 @@ NOTE(conformance_availability_obsoleted, none,
5347
5347
" conformance of %0 to %1 was obsoleted in %2 %3" ,
5348
5348
(Type, Type, StringRef, llvm::VersionTuple))
5349
5349
5350
- WARNING(conformance_availability_deprecated, none ,
5350
+ WARNING(conformance_availability_deprecated, Deprecation ,
5351
5351
" conformance of %0 to %1 %select{is|%select{is|was}4}2 "
5352
5352
" deprecated%select{| in %3%select{| %5}4}2%select{|: %6}6" ,
5353
5353
(Type, Type, bool , StringRef, bool , llvm::VersionTuple,
@@ -5493,31 +5493,31 @@ NOTE(specialize_found_function_of_type, none,
5493
5493
// MARK: Variable usage diagnostics
5494
5494
// ------------------------------------------------------------------------------
5495
5495
5496
- WARNING(pbd_never_used_stmtcond, none ,
5496
+ WARNING(pbd_never_used_stmtcond, NoUsage ,
5497
5497
" value %0 was defined but never used; consider replacing "
5498
5498
" with boolean test" ,
5499
5499
(Identifier))
5500
- WARNING(unused_setter_parameter, none ,
5500
+ WARNING(unused_setter_parameter, NoUsage ,
5501
5501
" setter argument %0 was never used, but the property was accessed" ,
5502
5502
(Identifier))
5503
5503
NOTE(fixit_for_unused_setter_parameter, none,
5504
5504
" did you mean to use %0 instead of accessing the property's current value?" , (Identifier))
5505
5505
5506
- WARNING(pbd_never_used, none ,
5506
+ WARNING(pbd_never_used, NoUsage ,
5507
5507
" initialization of %select{variable|immutable value}1 %0 was never used"
5508
5508
" ; consider replacing with assignment to '_' or removing it" ,
5509
5509
(Identifier, unsigned ))
5510
5510
5511
5511
5512
- WARNING(capture_never_used, none ,
5512
+ WARNING(capture_never_used, NoUsage ,
5513
5513
" capture %0 was never used" ,
5514
5514
(Identifier))
5515
5515
5516
- WARNING(variable_never_used, none ,
5516
+ WARNING(variable_never_used, NoUsage ,
5517
5517
" %select{variable|immutable value}1 %0 was never used; "
5518
5518
" consider replacing with '_' or removing it" ,
5519
5519
(Identifier, unsigned ))
5520
- WARNING(immutable_value_never_used_but_assigned, none ,
5520
+ WARNING(immutable_value_never_used_but_assigned, NoUsage ,
5521
5521
" immutable value %0 was never used; consider removing it" ,
5522
5522
(Identifier))
5523
5523
WARNING(variable_never_mutated, none,
@@ -5602,7 +5602,7 @@ ERROR(override_nsobject_hash_error,none,
5602
5602
" 'NSObject.hash(into:)' is not overridable; "
5603
5603
" did you mean to override 'NSObject.hash'?" , ())
5604
5604
5605
- WARNING(hashvalue_implementation,none ,
5605
+ WARNING(hashvalue_implementation,Deprecation ,
5606
5606
" 'Hashable.hashValue' is deprecated as a protocol requirement; "
5607
5607
" conform type %0 to 'Hashable' by implementing 'hash(into:)' instead" ,
5608
5608
(Type))
@@ -5722,10 +5722,10 @@ ERROR(property_wrapper_type_not_usable_from_inline,none,
5722
5722
" %select{%select{variable|constant}0|property}1 "
5723
5723
" must be '@usableFromInline' or public" ,
5724
5724
(bool , bool ))
5725
- WARNING(property_wrapper_wrapperValue,none ,
5725
+ WARNING(property_wrapper_wrapperValue,Deprecation ,
5726
5726
" property wrapper's 'wrapperValue' property should be renamed to "
5727
5727
" 'projectedValue'; use of 'wrapperValue' is deprecated" , ())
5728
- WARNING(property_wrapper_init_initialValue,none ,
5728
+ WARNING(property_wrapper_init_initialValue,Deprecation ,
5729
5729
" property wrapper's 'init(initialValue:)' should be renamed "
5730
5730
" to 'init(wrappedValue:)'; use of 'init(initialValue:)' is deprecated" ,
5731
5731
())
@@ -5822,7 +5822,7 @@ NOTE(result_builder_missing_build_limited_availability, none,
5822
5822
// MARK: Tuple Shuffle Diagnostics
5823
5823
// ------------------------------------------------------------------------------
5824
5824
5825
- WARNING(warn_reordering_tuple_shuffle_deprecated,none ,
5825
+ WARNING(warn_reordering_tuple_shuffle_deprecated,Deprecation ,
5826
5826
" expression shuffles the elements of this tuple; "
5827
5827
" this behavior is deprecated" , ())
5828
5828
0 commit comments