@@ -2174,9 +2174,6 @@ NOTE(protocol_witness_settable_conflict,none,
21742174 " candidate is not settable, but protocol requires it" , ())
21752175NOTE(protocol_witness_rethrows_conflict,none,
21762176 " candidate is not 'rethrows', but protocol requires it" , ())
2177- NOTE(protocol_witness_async_conflict,none,
2178- " candidate is %select{not |}0'async', but protocol requirement is%select{| not}0" ,
2179- (bool ))
21802177NOTE(protocol_witness_throws_conflict,none,
21812178 " candidate throws, but protocol does not allow it" , ())
21822179NOTE(protocol_witness_not_objc,none,
@@ -4036,6 +4033,16 @@ NOTE(note_error_to_optional,none,
40364033 " did you mean to handle error as optional value?" , ())
40374034NOTE(note_disable_error_propagation,none,
40384035 " did you mean to disable error propagation?" , ())
4036+
4037+ WARNING(no_throw_in_try,none,
4038+ " no calls to throwing functions occur within 'try' expression" , ())
4039+
4040+ WARNING(no_throw_in_do_with_catch,none,
4041+ " 'catch' block is unreachable because no errors are thrown in 'do' block" , ())
4042+
4043+ // ------------------------------------------------------------------------------
4044+ // MARK: Concurrency
4045+ // ------------------------------------------------------------------------------
40394046ERROR(async_call_without_await,none,
40404047 " call is 'async' but is not marked with 'await'" , ())
40414048ERROR(async_call_without_await_in_autoclosure,none,
@@ -4056,12 +4063,15 @@ ERROR(async_in_nonasync_function,none,
40564063 (bool , bool ))
40574064NOTE(note_add_async_to_function,none,
40584065 " add 'async' to function %0 to make it asynchronous" , (DeclName))
4059-
4060- WARNING(no_throw_in_try,none,
4061- " no calls to throwing functions occur within 'try' expression" , ())
4062-
4063- WARNING(no_throw_in_do_with_catch,none,
4064- " 'catch' block is unreachable because no errors are thrown in 'do' block" , ())
4066+ ERROR(not_objc_function_async,none,
4067+ " 'async' function cannot be represented in Objective-C" , ())
4068+ NOTE(not_objc_function_type_async,none,
4069+ " 'async' function types cannot be represented in Objective-C" , ())
4070+ NOTE(protocol_witness_async_conflict,none,
4071+ " candidate is %select{not |}0'async', but protocol requirement is%select{| not}0" ,
4072+ (bool ))
4073+ ERROR(async_autoclosure_nonasync_function,none,
4074+ " 'async' autoclosure parameter in a non-'async' function" , ())
40654075
40664076// ------------------------------------------------------------------------------
40674077// MARK: Type Check Types
@@ -4417,10 +4427,6 @@ NOTE(not_objc_generic_type_param,none,
44174427NOTE(not_objc_function_type_param,none,
44184428 " function types cannot be represented in Objective-C unless their "
44194429 " parameters and returns can be" , ())
4420- ERROR(not_objc_function_async,none,
4421- " 'async' function cannot be represented in Objective-C" , ())
4422- NOTE(not_objc_function_type_async,none,
4423- " 'async' function types cannot be represented in Objective-C" , ())
44244430NOTE(not_objc_function_type_throwing,none,
44254431 " throwing function types cannot be represented in Objective-C" , ())
44264432NOTE(objc_inferring_on_objc_protocol_member,none,
0 commit comments