5 const field dynamic #errors = const <dynamic>["pkg/front_end/testcases/illegal_n
amed_function_expression.dart:2:11: Error: A function expression can't have a re
turn type.\n var x = void f<T>(T t) {};\n ^", "pkg/front_end/testcases
/illegal_named_function_expression.dart:2:16: Error: A function expression can't
have a name.\n var x = void f<T>(T t) {};\n ^", "pkg/front_end/t
estcases/illegal_named_function_expression.dart:4:9: Error: A function expressio
n can't have a return type.\n print(void g<T>(T t) {});\n ^", "pkg/front
_end/testcases/illegal_named_function_expression.dart:4:14: Error: A function ex
pression can't have a name.\n print(void g<T>(T t) {});\n ^"]/* fro
m null */;
6 static method main() → dynamic {
7 <T extends core::Object>(T) → core::Null x = let final <T extends core::Object
>(T) → core::Null f = <T extends core::Object>(T t) → core::Null {} in f;
8 core::print(x.runtimeType);
9 core::print(let final <T extends core::Object>(T) → core::Null g = <T extends
core::Object>(T t) → core::Null {} in g);
Issue 2994973002: Implement type variables on local function declarations and expressions.
(Closed)
Created 3 years, 4 months ago by ahe
Modified 3 years, 4 months ago
Reviewers: danrubel, Johnni Winther, Paul Berry
Base URL:
Comments: 2