blob: 31ee2a4164ccb405a82f767601cf4072766d56cc [file] [log] [blame]
library test /*isNonNullableByDefault*/;
//
// Problems in library:
//
// pkg/front_end/testcases/inference/block_bodied_lambdas_downwards_incompatible_with_upwards_inference.dart:12:45: Error: A value of type 'int' can't be returned from a function with return type 'String'.
// return /*error:RETURN_OF_INVALID_TYPE*/ 1;
// ^
//
import self as self;
import "dart:core" as core;
static method main() dynamic {
function f() core::String
return "";
() core::String g = f;
g = () core::String {
return invalid-expression "pkg/front_end/testcases/inference/block_bodied_lambdas_downwards_incompatible_with_upwards_inference.dart:12:45: Error: A value of type 'int' can't be returned from a function with return type 'String'.
return /*error:RETURN_OF_INVALID_TYPE*/ 1;
^" in 1 as{TypeError,ForNonNullableByDefault} core::String;
};
}