| library /*isNonNullableByDefault*/; |
| // |
| // Problems in library: |
| // |
| // pkg/front_end/testcases/general/issue38253b.dart:6:3: Error: 'g' isn't a type. |
| // g f1() { |
| // ^ |
| // |
| // pkg/front_end/testcases/general/issue38253b.dart:10:3: Error: 'g' isn't a type. |
| // g f2() async { |
| // ^ |
| // |
| // pkg/front_end/testcases/general/issue38253b.dart:7:5: Error: A value must be explicitly returned from a non-void function. |
| // return; |
| // ^ |
| // |
| // pkg/front_end/testcases/general/issue38253b.dart:11:5: Error: A value must be explicitly returned from a non-void async function. |
| // return; |
| // ^ |
| // |
| import self as self; |
| import "dart:async" as asy; |
| import "dart:core" as core; |
| |
| static field () → Null a = () → Null { |
| function f1() → invalid-type { |
| return let final Never #t1 = invalid-expression "pkg/front_end/testcases/general/issue38253b.dart:7:5: Error: A value must be explicitly returned from a non-void function. |
| return; |
| ^" in null; |
| } |
| function f2() → invalid-type /* originally async */ { |
| final asy::_Future<dynamic> :async_future = new asy::_Future::•<dynamic>(); |
| core::bool* :is_sync = false; |
| FutureOr<dynamic>? :return_value; |
| (dynamic) → dynamic :async_op_then; |
| (core::Object, core::StackTrace) → dynamic :async_op_error; |
| core::int :await_jump_var = 0; |
| dynamic :await_ctx_var; |
| function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding |
| try { |
| #L1: |
| { |
| :return_value = let final Never #t2 = invalid-expression "pkg/front_end/testcases/general/issue38253b.dart:11:5: Error: A value must be explicitly returned from a non-void async function. |
| return; |
| ^" in null; |
| break #L1; |
| } |
| asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync); |
| return; |
| } |
| on dynamic catch(dynamic exception, core::StackTrace stack_trace) { |
| asy::_completeOnAsyncError(:async_future, exception, stack_trace, :is_sync); |
| } |
| :async_op_then = asy::_asyncThenWrapperHelper(:async_op); |
| :async_op_error = asy::_asyncErrorWrapperHelper(:async_op); |
| :async_op(){() → dynamic}; |
| :is_sync = true; |
| return :async_future; |
| } |
| }; |
| static method main() → dynamic {} |