@@ -315,12 +315,12 @@ ERROR(missing_never_call_closure,none,
315
315
(Type))
316
316
317
317
ERROR(missing_return_decl,none,
318
- " missing return in %1 expected to return %0" ,
319
- (Type, DescriptiveDeclKind ))
318
+ " missing return in %kindonly1 expected to return %0" ,
319
+ (Type, const AbstractFunctionDecl * ))
320
320
ERROR(missing_never_call_decl,none,
321
- " %1 with uninhabited return type %0 is missing "
321
+ " %kindonly1 with uninhabited return type %0 is missing "
322
322
" call to another never-returning function on all paths" ,
323
- (Type, DescriptiveDeclKind ))
323
+ (Type, const AbstractFunctionDecl * ))
324
324
325
325
NOTE(missing_return_last_expr_note,none,
326
326
" did you mean to return the last expression?" , ())
@@ -701,8 +701,9 @@ WARNING(warning_int_to_fp_inexact, none,
701
701
702
702
// Flow-isolation diagnostics
703
703
ERROR(isolated_after_nonisolated, none,
704
- " cannot access %1 %2 here in %select{nonisolated initializer|deinitializer}0" ,
705
- (bool , DescriptiveDeclKind, DeclName))
704
+ " cannot access %kind1 here in "
705
+ " %select{nonisolated initializer|deinitializer}0" ,
706
+ (bool , const ValueDecl *))
706
707
NOTE(nonisolated_blame, none, " after %1%2 %3, "
707
708
" only nonisolated properties of 'self' can be accessed from "
708
709
" %select{this init|a deinit}0" , (bool , StringRef, StringRef, DeclName))
@@ -981,16 +982,16 @@ NOTE(regionbasedisolation_type_use_after_send, none,
981
982
" sending value of non-Sendable type %0 to %1 callee risks causing data races between %1 and local %2 uses" ,
982
983
(Type, ActorIsolation, ActorIsolation))
983
984
NOTE(regionbasedisolation_type_use_after_send_callee, none,
984
- " sending value of non-Sendable type %0 to %1 %2 %3 risks causing data "
985
- " races between %1 and local %4 uses" ,
986
- (Type, ActorIsolation, DescriptiveDeclKind, DeclName , ActorIsolation))
985
+ " sending value of non-Sendable type %0 to %1 %kind2 risks causing data "
986
+ " races between %1 and local %3 uses" ,
987
+ (Type, ActorIsolation, const ValueDecl * , ActorIsolation))
987
988
988
989
NOTE(regionbasedisolation_named_info_send_yields_race, none,
989
990
" sending %1%0 to %2 callee risks causing data races between %2 and local %3 uses" ,
990
991
(Identifier, StringRef, ActorIsolation, ActorIsolation))
991
992
NOTE(regionbasedisolation_named_info_send_yields_race_callee, none,
992
- " sending %1%0 to %2 %3 %4 risks causing data races between %2 and local %5 uses" ,
993
- (Identifier, StringRef, ActorIsolation, DescriptiveDeclKind, DeclName , ActorIsolation))
993
+ " sending %1%0 to %2 %kind3 risks causing data races between %2 and local %4 uses" ,
994
+ (Identifier, StringRef, ActorIsolation, const ValueDecl * , ActorIsolation))
994
995
995
996
// Use after send closure.
996
997
NOTE(regionbasedisolation_type_isolated_capture_yields_race, none,
@@ -1013,8 +1014,8 @@ NOTE(regionbasedisolation_typed_use_after_sending, none,
1013
1014
" Passing value of non-Sendable type %0 as a 'sending' argument risks causing races in between local and caller code" ,
1014
1015
(Type))
1015
1016
NOTE(regionbasedisolation_typed_use_after_sending_callee, none,
1016
- " Passing value of non-Sendable type %0 as a 'sending' argument to %1 %2 risks causing races in between local and caller code" ,
1017
- (Type, DescriptiveDeclKind, DeclName ))
1017
+ " Passing value of non-Sendable type %0 as a 'sending' argument to %kind1 risks causing races in between local and caller code" ,
1018
+ (Type, const ValueDecl * ))
1018
1019
1019
1020
// ===
1020
1021
// Sending Never Sendable Emitter
@@ -1023,8 +1024,8 @@ NOTE(regionbasedisolation_named_send_never_sendable, none,
1023
1024
" sending %1%0 to %2 callee risks causing data races between %2 and %3 uses" ,
1024
1025
(Identifier, StringRef, ActorIsolation, StringRef))
1025
1026
NOTE(regionbasedisolation_named_send_never_sendable_callee, none,
1026
- " sending %1%0 to %2 %3 %4 risks causing data races between %2 and %5 uses" ,
1027
- (Identifier, StringRef, ActorIsolation, DescriptiveDeclKind, DeclName , StringRef))
1027
+ " sending %1%0 to %2 %kind3 risks causing data races between %2 and %4 uses" ,
1028
+ (Identifier, StringRef, ActorIsolation, const ValueDecl * , StringRef))
1028
1029
1029
1030
NOTE(regionbasedisolation_named_send_into_sending_param, none,
1030
1031
" %0%1 is passed as a 'sending' parameter; Uses in callee may race with "
@@ -1048,8 +1049,8 @@ NOTE(regionbasedisolation_typed_tns_passed_to_sending_closure_helper_have_value_
1048
1049
" closure captures %0 which is accessible to code in the current task" ,
1049
1050
(DeclName))
1050
1051
NOTE(regionbasedisolation_typed_tns_passed_to_sending_closure_helper_have_boxed_value_task_isolated, none,
1051
- " closure captures reference to mutable %1 %0 which is accessible to code in the current task" ,
1052
- (DeclName, DescriptiveDeclKind ))
1052
+ " closure captures reference to mutable %kind0 which is accessible to code in the current task" ,
1053
+ (const ValueDecl * ))
1053
1054
NOTE(regionbasedisolation_typed_tns_passed_to_sending_closure_helper_have_value_region, none,
1054
1055
" closure captures %1 which is accessible to %0 code" ,
1055
1056
(StringRef, DeclName))
@@ -1065,8 +1066,8 @@ NOTE(regionbasedisolation_closure_captures_actor, none,
1065
1066
(DeclName, StringRef))
1066
1067
1067
1068
NOTE(regionbasedisolation_typed_tns_passed_to_sending_callee, none,
1068
- " Passing %0 value of non-Sendable type %1 as a 'sending' parameter to %2 %3 risks causing races inbetween %0 uses and uses reachable from %3 " ,
1069
- (StringRef, Type, DescriptiveDeclKind, DeclName ))
1069
+ " Passing %0 value of non-Sendable type %1 as a 'sending' parameter to %kind2 risks causing races inbetween %0 uses and uses reachable from %2 " ,
1070
+ (StringRef, Type, const ValueDecl * ))
1070
1071
1071
1072
NOTE(regionbasedisolation_named_send_nt_asynclet_capture, none,
1072
1073
" sending %1 %0 into async let risks causing data races between nonisolated and %1 uses" ,
@@ -1075,8 +1076,8 @@ NOTE(regionbasedisolation_typed_sendneversendable_via_arg, none,
1075
1076
" sending %0 value of non-Sendable type %1 to %2 callee risks causing races in between %0 and %2 uses" ,
1076
1077
(StringRef, Type, ActorIsolation))
1077
1078
NOTE(regionbasedisolation_typed_sendneversendable_via_arg_callee, none,
1078
- " sending %0 value of non-Sendable type %1 to %2 %3 %4 risks causing races in between %0 and %2 uses" ,
1079
- (StringRef, Type, ActorIsolation, DescriptiveDeclKind, DeclName ))
1079
+ " sending %0 value of non-Sendable type %1 to %2 %kind3 risks causing races in between %0 and %2 uses" ,
1080
+ (StringRef, Type, ActorIsolation, const ValueDecl * ))
1080
1081
1081
1082
// Error that is only used when the send non sendable emitter cannot discover any
1082
1083
// information to give a better diagnostic.
0 commit comments