blob: a41f60c8095670c1e1e66724c0372939e9635648 [file] [log] [blame]
// Formatted problems:
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:11:89: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ 42
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:19:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello"
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:22:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello",
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:33:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
// Change the type of the list literal or the context in which it is used.
// List<int> l0 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[];
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:34:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
// Change the type of the list literal or the context in which it is used.
// List<int> l1 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[3];
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:36:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello"
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:35:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
// Change the type of the list literal or the context in which it is used.
// List<int> l2 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:39:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello",
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:38:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
// Change the type of the list literal or the context in which it is used.
// List<int> l3 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:47:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello"
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:50:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello",
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:58:89: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello"
// ^
//
// pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:61:89: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
// Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
// /*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ "hello",
// ^
library test;
import self as self;
import "dart:core" as core;
static method foo([core::List<core::String> list1 = const <core::String>[], core::List<core::String> list2 = const <core::String>[let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:11:89: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ 42
^" in 42 as{TypeError} core::String]]) → void {}
static method main() → void {
{
core::List<core::int> l0 = <core::int>[];
core::List<core::int> l1 = <core::int>[3];
core::List<core::int> l2 = <core::int>[let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:19:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\"
^" in "hello" as{TypeError} core::int];
core::List<core::int> l3 = <core::int>[let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:22:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
^" in "hello" as{TypeError} core::int, 3];
}
{
core::List<dynamic> l0 = <dynamic>[];
core::List<dynamic> l1 = <dynamic>[3];
core::List<dynamic> l2 = <dynamic>["hello"];
core::List<dynamic> l3 = <dynamic>["hello", 3];
}
{
core::List<core::int> l0 = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:33:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
Change the type of the list literal or the context in which it is used.
List<int> l0 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[];
^" in <core::num>[];
core::List<core::int> l1 = let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:34:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
Change the type of the list literal or the context in which it is used.
List<int> l1 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[3];
^" in <core::num>[3];
core::List<core::int> l2 = let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:35:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
Change the type of the list literal or the context in which it is used.
List<int> l2 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[
^" in <core::num>[let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:36:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\"
^" in "hello" as{TypeError} core::num];
core::List<core::int> l3 = let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:38:61: Error: The list literal type 'dart.core::List<dart.core::num>' isn't of expected type 'dart.core::List<dart.core::int>'.
Change the type of the list literal or the context in which it is used.
List<int> l3 = /*error:INVALID_CAST_LITERAL_LIST*/ <num>[
^" in <core::num>[let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:39:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
^" in "hello" as{TypeError} core::num, 3];
}
{
core::Iterable<core::int> i0 = <core::int>[];
core::Iterable<core::int> i1 = <core::int>[3];
core::Iterable<core::int> i2 = <core::int>[let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:47:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\"
^" in "hello" as{TypeError} core::int];
core::Iterable<core::int> i3 = <core::int>[let final<BottomType> #t11 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:50:50: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
^" in "hello" as{TypeError} core::int, 3];
}
{
const core::List<core::int> c0 = const <core::int>[];
const core::List<core::int> c1 = const <core::int>[3];
const core::List<core::int> c2 = const <core::int>[let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:58:89: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\"
^" in "hello" as{TypeError} core::int];
const core::List<core::int> c3 = const <core::int>[let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_list_literals_infer_downwards.dart:61:89: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
/*error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE,error:LIST_ELEMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
^" in "hello" as{TypeError} core::int, 3];
}
}