@@ -2363,6 +2363,18 @@ ERROR(extension_access_with_conformances,none,
23632363ERROR(experimental_tuple_extension,none,
23642364 " tuple extensions are experimental" ,
23652365 ())
2366+ ERROR(tuple_extension_wrong_type,none,
2367+ " tuple extension must be written as extension of %0" , (Type))
2368+ ERROR(tuple_extension_one_conformance,none,
2369+ " tuple extension must declare conformance to exactly one protocol" , ())
2370+ ERROR(tuple_extension_extra_requirement,none,
2371+ " tuple extension cannot require that %0 "
2372+ " %select{conforms to|subclasses|is the same type as|%error|%error}1 %2" ,
2373+ (Type, unsigned , Type))
2374+ ERROR(tuple_extension_missing_requirement,none,
2375+ " tuple extension must require that %0 conforms to %1" , (Type, Type))
2376+ ERROR(tuple_extension_nested_type,none,
2377+ " type %0 cannot be nested in tuple extension" , (const NominalTypeDecl *))
23662378ERROR(extension_metatype,none,
23672379 " cannot extend a metatype %0" , (Type))
23682380ERROR(extension_placeholder,none,
@@ -2731,10 +2743,23 @@ NOTE(ambiguous_witnesses_wrong_name,none,
27312743NOTE(no_witnesses_type,none,
27322744 " protocol requires nested type %0; add nested type %0 for conformance" ,
27332745 (const AssociatedTypeDecl *))
2734- NOTE(default_associated_type_req_fail,none,
2746+ NOTE(no_witnesses_type_tuple,none,
2747+ " protocol requires nested type %0; add type alias %0 with underlying type %1 "
2748+ " for conformance" ,
2749+ (const AssociatedTypeDecl *, Type))
2750+ NOTE(default_associated_type_unsatisfied_conformance,none,
2751+ " default type %0 for associated type %1 (from protocol %2) "
2752+ " does not conform to %3" ,
2753+ (Type, const AssociatedTypeDecl *, Type, Type))
2754+ NOTE(default_associated_type_unsatisfied_superclass,none,
2755+ " default type %0 for associated type %1 (from protocol %2) "
2756+ " does not inherit from %3" ,
2757+ (Type, const AssociatedTypeDecl *, Type, Type))
2758+ NOTE(default_associated_type_tuple,none,
27352759 " default type %0 for associated type %1 (from protocol %2) "
2736- " does not %select{inherit from|conform to}4 %3" ,
2737- (Type, const AssociatedTypeDecl *, Type, Type, bool ))
2760+ " is unsuitable for tuple conformance; the associated type requirement "
2761+ " must be fulfilled by a type alias with underlying type %3" ,
2762+ (Type, const AssociatedTypeDecl *, Type, Type))
27382763ERROR(associated_type_access,none,
27392764 " associated type in "
27402765 " %select{a private|a fileprivate|an internal|a package|a public|%error}0 protocol "
@@ -2762,10 +2787,19 @@ WARNING(associated_type_not_usable_from_inline_warn,none,
27622787NOTE(bad_associated_type_deduction,none,
27632788 " unable to infer associated type %0 for protocol %1" ,
27642789 (const AssociatedTypeDecl *, const ProtocolDecl *))
2765- NOTE(associated_type_deduction_witness_failed,none,
2790+ NOTE(associated_type_deduction_unsatisfied_conformance,none,
2791+ " candidate would match and infer %0 = %1 if %1 "
2792+ " conformed to %2" ,
2793+ (const AssociatedTypeDecl *, Type, Type))
2794+ NOTE(associated_type_deduction_unsatisfied_superclass,none,
27662795 " candidate would match and infer %0 = %1 if %1 "
2767- " %select{inherited from|conformed to}3 %2" ,
2768- (const AssociatedTypeDecl *, Type, Type, bool ))
2796+ " inherited from %2" ,
2797+ (const AssociatedTypeDecl *, Type, Type))
2798+ NOTE(associated_type_deduction_tuple,none,
2799+ " cannot infer %0 = %1 in tuple conformance because "
2800+ " the associated type requirement must be fulfilled by a type alias with "
2801+ " underlying type %2" ,
2802+ (const AssociatedTypeDecl *, Type, Type))
27692803NOTE(associated_type_witness_conform_impossible,none,
27702804 " candidate can not infer %0 = %1 because %1 "
27712805 " is not a nominal type and so can't conform to %2" ,
@@ -2856,9 +2890,17 @@ NOTE(protocol_witness_enum_case_payload, none,
28562890
28572891NOTE(protocol_witness_type,none,
28582892 " possibly intended match" , ())
2859- NOTE(protocol_witness_nonconform_type ,none,
2893+ NOTE(protocol_type_witness_unsatisfied_conformance ,none,
28602894 " possibly intended match %0 does not "
2861- " %select{inherit from|conform to}2 %1" , (Type, Type, bool ))
2895+ " conform to %1" , (Type, Type))
2896+ NOTE(protocol_type_witness_unsatisfied_superclass,none,
2897+ " possibly intended match %0 does not "
2898+ " inherit from %1" , (Type, Type))
2899+ NOTE(protocol_type_witness_tuple,none,
2900+ " possibly intended match %0 is unsuitable for tuple conformance; "
2901+ " the associated type requirement must be fulfilled by a type alias "
2902+ " with underlying type %1" ,
2903+ (Type, Type))
28622904
28632905NOTE(protocol_witness_circularity,none,
28642906 " candidate references itself" , ())
0 commit comments