blob: a7630c40713f41ee9c61963678002c4d5512c6b8 [file] [log] [blame]
library /*isNonNullableByDefault*/;
//
// Problems in library:
//
// pkg/front_end/testcases/general/constants/with_unevaluated_agnostic/const_collections.dart:27:7: Error: Expected 2 type arguments.
// const Map<bool> MapWithUnevaluated = {
// ^^^
//
import self as self;
import "dart:core" as core;
static const field core::List<core::bool> listWithUnevaluated = #C9;
static const field core::List<core::bool> listWithUnevaluatedSpread = #C12;
static const field core::Set<core::bool> setWithUnevaluated = #C18;
static const field core::Set<core::bool> setWithUnevaluatedSpread = #C20;
static const field core::List<core::int> a = #C21;
static const field core::List<core::int?> b = #C22;
static const field core::Set<core::List<core::int?>> setNotAgnosticOK = #C23;
static const field invalid-type MapWithUnevaluated = #C27;
static const field core::Map<core::List<core::int?>, core::int> mapNotAgnosticOK = #C30;
static method main() dynamic {
core::print(#C9);
core::print(#C12);
core::print(#C18);
core::print(#C20);
core::print(<core::String>{"hello"});
core::print(#C32);
}
constants {
#C1 = "foo"
#C2 = eval const core::bool::fromEnvironment(#C1)
#C3 = eval const <dynamic>[#C2]
#C4 = "bar"
#C5 = eval const core::bool::fromEnvironment(#C4)
#C6 = eval const <dynamic>[#C5]
#C7 = true
#C8 = <core::bool*>[#C7]
#C9 = eval #C3 + #C6 + #C8
#C10 = false
#C11 = <core::bool*>[#C10]
#C12 = eval #C8 + #C9 + #C11
#C13 = eval const core::bool::fromEnvironment(#C1)
#C14 = eval const <dynamic>{#C13}
#C15 = eval const core::bool::fromEnvironment(#C4)
#C16 = eval const <dynamic>{#C15}
#C17 = <core::bool*>{#C7}
#C18 = eval #C14 + #C16 + #C17
#C19 = <core::bool*>{#C10}
#C20 = eval #C17 + #C18 + #C19
#C21 = <core::int*>[]
#C22 = <core::int?>[]
#C23 = <core::List<core::int?>*>{#C21, #C22}
#C24 = eval const core::bool::fromEnvironment(#C1)
#C25 = eval const core::bool::fromEnvironment(#C4)
#C26 = eval const <dynamic, dynamic>{#C24: #C25}
#C27 = eval #C26
#C28 = 0
#C29 = 1
#C30 = <core::List<core::int?>*, core::int*>{#C21:#C28, #C22:#C29)
#C31 = "hello"
#C32 = <core::String*>{#C31}
}
Extra constant evaluation status:
Evaluated with empty environment: ConstantExpression @ org-dartlang-testcase:///const_collections.dart:34:9 -> ListConstant(const <bool*>[false, false, true])
Evaluated with empty environment: ConstantExpression @ org-dartlang-testcase:///const_collections.dart:35:9 -> ListConstant(const <bool*>[true, false, false, true, false])
Evaluated with empty environment: ConstantExpression @ org-dartlang-testcase:///const_collections.dart:5:40 -> ListConstant(const <bool*>[false, false, true])
Evaluated with empty environment: ConstantExpression @ org-dartlang-testcase:///const_collections.dart:10:46 -> ListConstant(const <bool*>[true, false, false, true, false])
Evaluated with empty environment: ConstantExpression @ org-dartlang-testcase:///const_collections.dart:27:38 -> MapConstant(const <bool*, bool*>{false: false})
Extra constant evaluation: evaluated: 16, effectively constant: 5