Files
sdk/pkg/vm/testcases/bytecode/literals.dart.expect
T
asiva 393468dc89 This is a trial submit of the unfork CL, it will be reverted immediately.
This commit is being done so we can roll it into Flutter and run some device lab testing to see the effect this CL will have on Flutter.

[BUILD] - Initial CL to unfork the NNBD Dart SDK

- Flips the flag from --nnbd to --no-nnbd so that by default it builds
  the NNBD version
- using the --no-nnbd flag results in the SDK being built in a
  directory which has the 'Legacy' suffix added to it
  (e.g: out/DebugX64Legacy)
- the '--enable-experiment=non-nullable' flag still needs to be passed
  in during execution so that CFE runs in that mode. This is different
  from the 'null_safety' flag

Change-Id: I83c813aee2a5b61ad876d8a7b0988705bb24c839
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/144082
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-04-20 03:46:06 +00:00

1014 lines
32 KiB
Plaintext

main = #lib::main;
[@vm.bytecode=
BytecodeMetadata {
Bytecode (version: stable)
Main library: #lib
Library '#lib'
name '#lib'
script '#lib'
Class '', script = '#lib'
Field 'c1', type = #lib::A, getter = 'get:c1', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 2, #lib::A::_name (field): 'A.elem3'}
}
Field 'c2', type = dart:core::String, reflectable, static, const, final, has-initializer
value = 'hello!'
Field 'c3', type = dart:core::int, reflectable, static, const, final, has-initializer
value = const 6
Field 'c4', type = #lib::C, getter = 'get:c4', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::C {#lib::C::j (field): const 3, #lib::B::i (field): const 15}
}
Field 'c5', type = #lib::D, getter = 'get:c5', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::D {#lib::D::x (field): const #lib::B {#lib::B::i (field): const 4}, #lib::D::y (field): null}
}
Field 'fieldWithDoubleLiteralInitializer', type = dart:core::double, reflectable, static, has-initializer
value = const 1.0
Function 'test_constants1', static, reflectable, debuggable
parameters [] (required: 0)
return-type void
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
DirectCall CP#1, 1
Drop1
PushConstant CP#3
DirectCall CP#1, 1
Drop1
PushInt 6
DirectCall CP#1, 1
Drop1
PushConstant CP#4
DirectCall CP#1, 1
Drop1
PushConstant CP#5
DirectCall CP#1, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 2, #lib::A::_name (field): 'A.elem3'}
[1] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[2] = Reserved
[3] = ObjectRef 'hello!'
[4] = ObjectRef const #lib::C {#lib::C::j (field): const 3, #lib::B::i (field): const 15}
[5] = ObjectRef const #lib::D {#lib::D::x (field): const #lib::B {#lib::B::i (field): const 4}, #lib::D::y (field): null}
}
Function 'test_constants2', static, reflectable, debuggable
parameters [] (required: 0)
return-type void
Bytecode {
Entry 0
CheckStack 0
PushInt 42
DirectCall CP#0, 1
Drop1
PushConstant CP#2
DirectCall CP#0, 1
Drop1
PushConstant CP#3
DirectCall CP#0, 1
Drop1
PushConstant CP#4
DirectCall CP#0, 1
Drop1
PushConstant CP#5
DirectCall CP#0, 1
Drop1
PushConstant CP#6
DirectCall CP#0, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[1] = Reserved
[2] = ObjectRef 'foo'
[3] = ObjectRef const #lib::A {#lib::A::index (field): const 1, #lib::A::_name (field): 'A.elem2'}
[4] = ObjectRef const <dart:core::Object> [const 42, 'foo', dart:core::int]
[5] = ObjectRef const dart:core::_ImmutableMap < dart:core::String, #lib::A > {dart:core::_ImmutableMap::_kvPairs (field): const <dynamic> ['E2', const #lib::A {#lib::A::index (field): const 1, #lib::A::_name (field): 'A.elem2'}, 'E4', const #lib::A {#lib::A::index (field): const 3, #lib::A::_name (field): 'A.elem4'}]}
[6] = ObjectRef const #lib::D {#lib::D::x (field): const #lib::C {#lib::C::j (field): const 9, #lib::B::i (field): const 30}, #lib::D::y (field): const dart:core::_ImmutableMap < dart:core::String, dart:core::Object > {dart:core::_ImmutableMap::_kvPairs (field): const <dynamic> ['foo', const 42, 'bar', const #lib::B {#lib::B::i (field): const 6}]}}
}
Function 'test_list_literal', static, reflectable, debuggable
parameters [dart:core::int 'a'] (required: 1)
return-type void
Bytecode {
Entry 1
CheckStack 0
PushConstant CP#0
StoreLocal r0
Push r0
PushInt 3
CreateArrayTOS
StoreLocal r0
Push r0
PushInt 0
PushInt 1
StoreIndexedTOS
Push r0
PushInt 1
Push FP[-5]
StoreIndexedTOS
Push r0
PushInt 2
PushInt 3
StoreIndexedTOS
DirectCall CP#1, 2
DirectCall CP#3, 1
Drop1
PushConstant CP#5
StoreLocal r0
Push r0
PushInt 3
CreateArrayTOS
StoreLocal r0
Push r0
PushInt 0
PushConstant CP#6
StoreIndexedTOS
Push r0
PushInt 1
Push FP[-5]
InterfaceCall CP#7, 1
StoreIndexedTOS
Push r0
PushInt 2
PushConstant CP#9
StoreIndexedTOS
DirectCall CP#1, 2
DirectCall CP#3, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = ObjectRef < dart:core::int >
[1] = DirectCall 'dart:core::List::_fromLiteral (constructor)', ArgDesc num-args 2, num-type-args 0, names []
[2] = Reserved
[3] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[4] = Reserved
[5] = ObjectRef < dart:core::String >
[6] = ObjectRef 'a'
[7] = InterfaceCall 'dart:core::int::toString', ArgDesc num-args 1, num-type-args 0, names []
[8] = Reserved
[9] = ObjectRef 'b'
}
Function 'test_map_literal', static, reflectable, debuggable
type-params <dart:core::Object T>
parameters [dart:core::int 'a', dart:core::int 'b', #lib::test_map_literal::TypeParam/0 'c'] (required: 3)
return-type void
Bytecode {
Entry 2
CheckFunctionTypeArgs 1, r0
CheckStack 0
PushConstant CP#0
PushConstant CP#1
PushInt 4
CreateArrayTOS
StoreLocal r1
Push r1
PushInt 0
PushInt 1
StoreIndexedTOS
Push r1
PushInt 1
Push FP[-7]
StoreIndexedTOS
Push r1
PushInt 2
Push FP[-6]
StoreIndexedTOS
Push r1
PushInt 3
PushInt 2
StoreIndexedTOS
DirectCall CP#2, 2
DirectCall CP#4, 1
Drop1
PushConstant CP#6
PushConstant CP#1
PushInt 4
CreateArrayTOS
StoreLocal r1
Push r1
PushInt 0
PushConstant CP#7
StoreIndexedTOS
Push r1
PushInt 1
Push FP[-7]
StoreIndexedTOS
Push r1
PushInt 2
Push FP[-6]
InterfaceCall CP#8, 1
StoreIndexedTOS
Push r1
PushInt 3
PushInt 3
StoreIndexedTOS
DirectCall CP#2, 2
DirectCall CP#4, 1
Drop1
PushNull
Push r0
InstantiateTypeArgumentsTOS 0, CP#10
PushConstant CP#11
DirectCall CP#2, 2
DirectCall CP#4, 1
Drop1
PushNull
Push r0
InstantiateTypeArgumentsTOS 0, CP#12
PushConstant CP#1
PushInt 2
CreateArrayTOS
StoreLocal r1
Push r1
PushInt 0
Push FP[-5]
StoreIndexedTOS
Push r1
PushInt 1
PushInt 4
StoreIndexedTOS
DirectCall CP#2, 2
DirectCall CP#4, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = ObjectRef < dart:core::int, dart:core::int >
[1] = ObjectRef < dynamic >
[2] = DirectCall 'dart:core::Map::_fromLiteral (constructor)', ArgDesc num-args 2, num-type-args 0, names []
[3] = Reserved
[4] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[5] = Reserved
[6] = ObjectRef < dart:core::String, dart:core::int >
[7] = ObjectRef 'foo'
[8] = InterfaceCall 'dart:core::int::toString', ArgDesc num-args 1, num-type-args 0, names []
[9] = Reserved
[10] = ObjectRef < dart:core::String, #lib::test_map_literal::TypeParam/0 >
[11] = ObjectRef const <dynamic> []
[12] = ObjectRef < #lib::test_map_literal::TypeParam/0, dart:core::int >
}
Function 'test_symbol', static, reflectable, debuggable
parameters [] (required: 0)
return-type void
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
DirectCall CP#1, 1
Drop1
PushConstant CP#3
DirectCall CP#1, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const 'test_symbol'
[1] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[2] = Reserved
[3] = ObjectRef const '_private_symbol'
}
Function 'test_type_literal', static, reflectable, debuggable
type-params <dart:core::Object T>
parameters [] (required: 0)
return-type void
Bytecode {
Entry 1
CheckFunctionTypeArgs 1, r0
CheckStack 0
PushConstant CP#0
DirectCall CP#1, 1
Drop1
PushNull
Push r0
InstantiateType CP#3
DirectCall CP#1, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = Type dart:core::String
[1] = DirectCall 'dart:core::print', ArgDesc num-args 1, num-type-args 0, names []
[2] = Reserved
[3] = Type #lib::test_type_literal::TypeParam/0
}
Function 'testGenericConstInstance', static, reflectable, debuggable
parameters [] (required: 0)
return-type dynamic
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::F < dart:core::Map < dart:core::int, dart:core::String >, dart:core::int, dart:core::String > {}
}
Function 'testGenericFunctionTypeLiteral', static, reflectable, debuggable
parameters [] (required: 0)
return-type dynamic
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = Type FunctionType <dart:core::Object X> (null::TypeParam/0) -> null::TypeParam/0
}
Function 'testFieldWithDoubleLiteralInitializer', static, reflectable, debuggable
parameters [] (required: 0)
return-type dynamic
Bytecode {
Entry 0
CheckStack 0
LoadStatic CP#0
ReturnTOS
}
ConstantPool {
[0] = StaticField #lib::fieldWithDoubleLiteralInitializer (field)
}
Function 'main', static, reflectable, debuggable
parameters [] (required: 0)
return-type dynamic
Bytecode {
Entry 0
CheckStack 0
PushNull
ReturnTOS
}
ConstantPool {
}
Class 'A', script = '#lib', enum
extends dart:core::Object
Field 'index', type = dart:core::int, getter = 'get:index', reflectable, final
value = null
Field '_name', type = dart:core::String, getter = 'get:_name', reflectable, final
value = null
Field 'values', type = dart:core::List < #lib::A >, getter = 'get:values', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const <#lib::A> [const #lib::A {#lib::A::index (field): const 0, #lib::A::_name (field): 'A.elem1'}, const #lib::A {#lib::A::index (field): const 1, #lib::A::_name (field): 'A.elem2'}, const #lib::A {#lib::A::index (field): const 2, #lib::A::_name (field): 'A.elem3'}, const #lib::A {#lib::A::index (field): const 3, #lib::A::_name (field): 'A.elem4'}]
}
Field 'elem1', type = #lib::A, getter = 'get:elem1', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 0, #lib::A::_name (field): 'A.elem1'}
}
Field 'elem2', type = #lib::A, getter = 'get:elem2', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 1, #lib::A::_name (field): 'A.elem2'}
}
Field 'elem3', type = #lib::A, getter = 'get:elem3', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 2, #lib::A::_name (field): 'A.elem3'}
}
Field 'elem4', type = #lib::A, getter = 'get:elem4', reflectable, static, const, final, has-initializer
initializer
Bytecode {
Entry 0
CheckStack 0
PushConstant CP#0
ReturnTOS
}
ConstantPool {
[0] = ObjectRef const #lib::A {#lib::A::index (field): const 3, #lib::A::_name (field): 'A.elem4'}
}
Function '', constructor, const, reflectable, debuggable
parameters [dart:core::int 'index', dart:core::String '_name'] (required: 2)
return-type #lib::A
Bytecode {
Entry 0
CheckStack 0
Push FP[-7]
Push FP[-6]
StoreFieldTOS CP#0
Push FP[-7]
Push FP[-5]
StoreFieldTOS CP#2
Push FP[-7]
DirectCall CP#4, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = InstanceField #lib::A::index (field)
[1] = Reserved
[2] = InstanceField #lib::A::_name (field)
[3] = Reserved
[4] = DirectCall 'dart:core::Object:: (constructor)', ArgDesc num-args 1, num-type-args 0, names []
[5] = Reserved
}
Function 'toString', reflectable, debuggable
parameters [] (required: 0)
return-type dart:core::String
Bytecode {
Entry 0
CheckStack 0
Push FP[-5]
DirectCall CP#0, 1
ReturnTOS
}
ConstantPool {
[0] = DirectCall '#lib::A::get:_name', ArgDesc num-args 1, num-type-args 0, names []
[1] = Reserved
}
Function 'get:_identityHashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function '_instanceOf', abstract, debuggable
parameters [dynamic 'instantiatorTypeArguments', dynamic 'functionTypeArguments', dynamic 'type'] (required: 3)
return-type dart:core::bool
Function '_simpleInstanceOf', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfTrue', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfFalse', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '==', abstract, debuggable
parameters [dynamic 'other'] (required: 1)
return-type dart:core::bool
Function 'get:hashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function 'noSuchMethod', abstract, debuggable
parameters [dart:core::Invocation 'invocation'] (required: 1)
return-type dynamic
Function 'get:runtimeType', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::Type
Class 'B', script = '#lib'
extends dart:core::Object
Field 'i', type = dart:core::int, getter = 'get:i', reflectable, final
value = null
Function '', constructor, const, reflectable, debuggable
parameters [dart:core::int 'i'] (required: 1)
return-type #lib::B
Bytecode {
Entry 0
CheckStack 0
Push FP[-6]
Push FP[-5]
StoreFieldTOS CP#0
Push FP[-6]
DirectCall CP#2, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = InstanceField #lib::B::i (field)
[1] = Reserved
[2] = DirectCall 'dart:core::Object:: (constructor)', ArgDesc num-args 1, num-type-args 0, names []
[3] = Reserved
}
Function 'get:_identityHashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function '_instanceOf', abstract, debuggable
parameters [dynamic 'instantiatorTypeArguments', dynamic 'functionTypeArguments', dynamic 'type'] (required: 3)
return-type dart:core::bool
Function '_simpleInstanceOf', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfTrue', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfFalse', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '==', abstract, debuggable
parameters [dynamic 'other'] (required: 1)
return-type dart:core::bool
Function 'get:hashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function 'toString', abstract, debuggable
parameters [] (required: 0)
return-type dart:core::String
Function 'noSuchMethod', abstract, debuggable
parameters [dart:core::Invocation 'invocation'] (required: 1)
return-type dynamic
Function 'get:runtimeType', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::Type
Class 'C', script = '#lib'
extends #lib::B
Field 'j', type = dart:core::int, getter = 'get:j', reflectable, final
value = null
Function '', constructor, const, reflectable, debuggable
parameters [dart:core::int 'a', dart:core::int 'b', dart:core::int 'c'] (required: 3)
return-type #lib::C
Bytecode {
Entry 0
CheckStack 0
Push FP[-8]
Push FP[-7]
Push FP[-6]
AddInt
StoreFieldTOS CP#0
Push FP[-8]
Push FP[-5]
PushInt 5
MulInt
DirectCall CP#2, 2
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = InstanceField #lib::C::j (field)
[1] = Reserved
[2] = DirectCall '#lib::B:: (constructor)', ArgDesc num-args 2, num-type-args 0, names []
[3] = Reserved
}
Class 'D', script = '#lib'
extends dart:core::Object
Field 'x', type = dynamic, getter = 'get:x', reflectable, final
value = null
Field 'y', type = dynamic, getter = 'get:y', reflectable, final
value = null
Function '', constructor, const, has-optional-positional-params, reflectable, debuggable
parameters [dynamic 'x', dynamic 'y'] (required: 1)
return-type #lib::D
Bytecode {
EntryOptional 2, 1, 0
LoadConstant r2, CP#0
Frame 0
CheckStack 0
Push r0
Push r1
StoreFieldTOS CP#1
Push r0
Push r2
StoreFieldTOS CP#3
Push r0
DirectCall CP#5, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = ObjectRef null
[1] = InstanceField #lib::D::x (field)
[2] = Reserved
[3] = InstanceField #lib::D::y (field)
[4] = Reserved
[5] = DirectCall 'dart:core::Object:: (constructor)', ArgDesc num-args 1, num-type-args 0, names []
[6] = Reserved
}
Function 'get:_identityHashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function '_instanceOf', abstract, debuggable
parameters [dynamic 'instantiatorTypeArguments', dynamic 'functionTypeArguments', dynamic 'type'] (required: 3)
return-type dart:core::bool
Function '_simpleInstanceOf', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfTrue', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfFalse', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '==', abstract, debuggable
parameters [dynamic 'other'] (required: 1)
return-type dart:core::bool
Function 'get:hashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function 'toString', abstract, debuggable
parameters [] (required: 0)
return-type dart:core::String
Function 'noSuchMethod', abstract, debuggable
parameters [dart:core::Invocation 'invocation'] (required: 1)
return-type dynamic
Function 'get:runtimeType', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::Type
Class 'E', script = '#lib'
type-params <dart:core::Object T> (args: 1)
extends dart:core::Object
Function '', constructor, const, reflectable, debuggable
parameters [] (required: 0)
return-type #lib::E < #lib::E::TypeParam/0 >
Bytecode {
Entry 0
CheckStack 0
Push FP[-5]
DirectCall CP#0, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = DirectCall 'dart:core::Object:: (constructor)', ArgDesc num-args 1, num-type-args 0, names []
[1] = Reserved
}
Function 'get:_identityHashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function '_instanceOf', abstract, debuggable
parameters [dynamic 'instantiatorTypeArguments', dynamic 'functionTypeArguments', dynamic 'type'] (required: 3)
return-type dart:core::bool
Function '_simpleInstanceOf', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfTrue', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '_simpleInstanceOfFalse', abstract, debuggable
parameters [dynamic 'type'] (required: 1)
return-type dart:core::bool
Function '==', abstract, debuggable
parameters [dynamic 'other'] (required: 1)
return-type dart:core::bool
Function 'get:hashCode', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::int
Function 'toString', abstract, debuggable
parameters [] (required: 0)
return-type dart:core::String
Function 'noSuchMethod', abstract, debuggable
parameters [dart:core::Invocation 'invocation'] (required: 1)
return-type dynamic
Function 'get:runtimeType', getter, abstract, debuggable
parameters [] (required: 0)
return-type dart:core::Type
Class 'F', script = '#lib'
type-params <dart:core::Object P, dart:core::Object Q> (args: 3)
extends #lib::E < dart:core::Map < #lib::F::TypeParam/0, #lib::F::TypeParam/1 > >
Function '', constructor, const, reflectable, debuggable
parameters [] (required: 0)
return-type #lib::F < dart:core::Map < #lib::F::TypeParam/0, #lib::F::TypeParam/1 >, #lib::F::TypeParam/0, #lib::F::TypeParam/1 >
Bytecode {
Entry 0
CheckStack 0
Push FP[-5]
DirectCall CP#0, 1
Drop1
PushNull
ReturnTOS
}
ConstantPool {
[0] = DirectCall '#lib::E:: (constructor)', ArgDesc num-args 1, num-type-args 0, names []
[1] = Reserved
}
}
]library #lib from "#lib" as #lib {
typedef GenericFunctionType = <X extends dart.core::Object* = dynamic>(X*) →* X*;
class A extends dart.core::Object /*isEnum*/ {
final field dart.core::int* index;
final field dart.core::String* _name;
static const field dart.core::List<#lib::A*>* values = #C13;
static const field #lib::A* elem1 = #C3;
static const field #lib::A* elem2 = #C6;
static const field #lib::A* elem3 = #C9;
static const field #lib::A* elem4 = #C12;
const constructor •(dart.core::int* index, dart.core::String* _name) → #lib::A*
: #lib::A::index = index, #lib::A::_name = _name, super dart.core::Object::•()
;
method toString() → dart.core::String*
return this.{=#lib::A::_name};
abstract member-signature get _identityHashCode() → dart.core::int*;
abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOf(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfTrue(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfFalse(dynamic type) → dart.core::bool*;
abstract member-signature operator ==(dynamic other) → dart.core::bool*;
abstract member-signature get hashCode() → dart.core::int*;
abstract member-signature method noSuchMethod(dart.core::Invocation* invocation) → dynamic;
abstract member-signature get runtimeType() → dart.core::Type*;
}
class B extends dart.core::Object /*hasConstConstructor*/ {
final field dart.core::int* i;
const constructor •(dart.core::int* i) → #lib::B*
: #lib::B::i = i, super dart.core::Object::•()
;
abstract member-signature get _identityHashCode() → dart.core::int*;
abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOf(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfTrue(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfFalse(dynamic type) → dart.core::bool*;
abstract member-signature operator ==(dynamic other) → dart.core::bool*;
abstract member-signature get hashCode() → dart.core::int*;
abstract member-signature method toString() → dart.core::String*;
abstract member-signature method noSuchMethod(dart.core::Invocation* invocation) → dynamic;
abstract member-signature get runtimeType() → dart.core::Type*;
}
class C extends #lib::B /*hasConstConstructor*/ {
final field dart.core::int* j;
const constructor •(dart.core::int* a, dart.core::int* b, dart.core::int* c) → #lib::C*
: #lib::C::j = a.{dart.core::num::+}(b), super #lib::B::•(c.{dart.core::num::*}(5))
;
}
class D extends dart.core::Object /*hasConstConstructor*/ {
final field dynamic x;
final field dynamic y;
const constructor •(dynamic x, [dynamic y = #C14]) → #lib::D*
: #lib::D::x = x, #lib::D::y = y, super dart.core::Object::•()
;
abstract member-signature get _identityHashCode() → dart.core::int*;
abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOf(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfTrue(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfFalse(dynamic type) → dart.core::bool*;
abstract member-signature operator ==(dynamic other) → dart.core::bool*;
abstract member-signature get hashCode() → dart.core::int*;
abstract member-signature method toString() → dart.core::String*;
abstract member-signature method noSuchMethod(dart.core::Invocation* invocation) → dynamic;
abstract member-signature get runtimeType() → dart.core::Type*;
}
class E<T extends dart.core::Object* = dynamic> extends dart.core::Object /*hasConstConstructor*/ {
const constructor •() → #lib::E<#lib::E::T*>*
: super dart.core::Object::•()
;
abstract member-signature get _identityHashCode() → dart.core::int*;
abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOf(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfTrue(dynamic type) → dart.core::bool*;
abstract member-signature method _simpleInstanceOfFalse(dynamic type) → dart.core::bool*;
abstract member-signature operator ==(dynamic other) → dart.core::bool*;
abstract member-signature get hashCode() → dart.core::int*;
abstract member-signature method toString() → dart.core::String*;
abstract member-signature method noSuchMethod(dart.core::Invocation* invocation) → dynamic;
abstract member-signature get runtimeType() → dart.core::Type*;
}
class F<P extends dart.core::Object* = dynamic, Q extends dart.core::Object* = dynamic> extends #lib::E<dart.core::Map<#lib::F::P*, #lib::F::Q*>*> /*hasConstConstructor*/ {
const constructor •() → #lib::F<#lib::F::P*, #lib::F::Q*>*
: super #lib::E::•()
;
}
static const field #lib::A* c1 = #C9;
static const field dart.core::String* c2 = #C15;
static const field dart.core::int* c3 = #C16;
static const field #lib::C* c4 = #C18;
static const field #lib::D* c5 = #C21;
static field dart.core::double* fieldWithDoubleLiteralInitializer = 1.0;
static method test_constants1() → void {
dart.core::print(#C9);
dart.core::print(#C15);
dart.core::print(#C16);
dart.core::print(#C18);
dart.core::print(#C21);
}
static method test_constants2() → void {
dart.core::print(42);
dart.core::print("foo");
dart.core::print(#C6);
dart.core::print(#C25);
dart.core::print(#C29);
dart.core::print(#C37);
}
static method test_list_literal(dart.core::int* a) → void {
dart.core::print(<dart.core::int*>[1, a, 3]);
dart.core::print(<dart.core::String*>["a", a.{dart.core::int::toString}(), "b"]);
}
static method test_map_literal<T extends dart.core::Object* = dynamic>(dart.core::int* a, dart.core::int* b, #lib::test_map_literal::T* c) → void {
dart.core::print(<dart.core::int*, dart.core::int*>{1: a, b: 2});
dart.core::print(<dart.core::String*, dart.core::int*>{"foo": a, b.{dart.core::int::toString}(): 3});
dart.core::print(<dart.core::String*, #lib::test_map_literal::T*>{});
dart.core::print(<#lib::test_map_literal::T*, dart.core::int*>{c: 4});
}
static method test_symbol() → void {
dart.core::print(#C38);
dart.core::print(#C39);
}
static method test_type_literal<T extends dart.core::Object* = dynamic>() → void {
dart.core::print(dart.core::String*);
dart.core::print(#lib::test_type_literal::T*);
}
static method testGenericConstInstance() → dynamic
return #C40;
static method testGenericFunctionTypeLiteral() → dynamic
return <X extends dart.core::Object* = dynamic>(X*) →* X*;
static method testFieldWithDoubleLiteralInitializer() → dynamic
return #lib::fieldWithDoubleLiteralInitializer;
static method main() → dynamic {}
}
constants {
#C1 = 0
#C2 = "A.elem1"
#C3 = #lib::A {index:#C1, _name:#C2}
#C4 = 1
#C5 = "A.elem2"
#C6 = #lib::A {index:#C4, _name:#C5}
#C7 = 2
#C8 = "A.elem3"
#C9 = #lib::A {index:#C7, _name:#C8}
#C10 = 3
#C11 = "A.elem4"
#C12 = #lib::A {index:#C10, _name:#C11}
#C13 = <#lib::A*>[#C3, #C6, #C9, #C12]
#C14 = null
#C15 = "hello!"
#C16 = 6
#C17 = 15
#C18 = #lib::C {j:#C10, i:#C17}
#C19 = 4
#C20 = #lib::B {i:#C19}
#C21 = #lib::D {x:#C20, y:#C14}
#C22 = 42
#C23 = "foo"
#C24 = TypeLiteralConstant(dart.core::int*)
#C25 = <dart.core::Object*>[#C22, #C23, #C24]
#C26 = "E2"
#C27 = "E4"
#C28 = <dynamic>[#C26, #C6, #C27, #C12]
#C29 = dart.core::_ImmutableMap<dart.core::String*, #lib::A*> {_kvPairs:#C28}
#C30 = 9
#C31 = 30
#C32 = #lib::C {j:#C30, i:#C31}
#C33 = "bar"
#C34 = #lib::B {i:#C16}
#C35 = <dynamic>[#C23, #C22, #C33, #C34]
#C36 = dart.core::_ImmutableMap<dart.core::String*, dart.core::Object*> {_kvPairs:#C35}
#C37 = #lib::D {x:#C32, y:#C36}
#C38 = #test_symbol
#C39 = ##lib::_private_symbol
#C40 = #lib::F<dart.core::int*, dart.core::String*> {}
}