blob: 45adcb4b45340c239efd96e480e41f284969069c [file]
library /*isNonNullableByDefault*/;
import self as self;
import "dart:core" as core;
import "dart:_internal" as _in;
class Enum extends core::_Enum /*isEnum*/ {
static const field core::List<self::Enum> values = #C10;
enum-element static const field self::Enum a = #C3;
enum-element static const field self::Enum b = #C6;
enum-element static const field self::Enum c = #C9;
const constructor •(core::int #index, core::String #name) → self::Enum
: super core::_Enum::•(#index, #name)
;
method _enumToString() core::String
return "Enum.${this.{core::_Enum::_name}{core::String}}";
}
static method method(dynamic e) dynamic {
#L1:
switch(e) {
#L2:
case #C1:
{
core::print(0);
break #L1;
}
#L3:
case #C4:
{
core::print(1);
break #L1;
}
#L4:
case #C7:
{
core::print(2);
}
}
#L5:
{
final dynamic #t1 = e;
final core::int #t2 = -1;
final core::bool #t3 = false;
if(!#t3 && #t1 is core::int) {
if(e =={core::Object::==}{(core::Object) core::bool} 0) {
#t2 = 0;
#t3 = true;
}
}
if(!#t3 && #t1 is core::int) {
if(e =={core::Object::==}{(core::Object) core::bool} 1) {
#t2 = 1;
#t3 = true;
}
}
if(!#t3 && #t1 is core::int) {
if(e =={core::Object::==}{(core::Object) core::bool} 2) {
#t2 = 2;
#t3 = true;
}
}
switch(#t2) {
#L6:
case #C1:
{
{
core::print(0);
break #L5;
}
}
#L7:
case #C4:
{
{
core::print(1);
break #L5;
}
}
#L8:
case #C7:
{
{
core::print(2);
}
}
}
}
}
static method method2(self::Enum e) dynamic {
#L9:
switch(e) /*isExplicitlyExhaustive*/ {
#L10:
case #C3:
{
core::print(0);
break #L9;
}
#L11:
case #C6:
{
core::print(1);
break #L9;
}
#L12:
case #C9:
{
core::print(2);
break #L9;
}
#L13:
default:
throw new _in::ReachabilityError::•("`null` encountered as case in a switch expression with a non-nullable enum type.");
}
}
constants {
#C1 = 0
#C2 = "a"
#C3 = self::Enum {index:#C1, _name:#C2}
#C4 = 1
#C5 = "b"
#C6 = self::Enum {index:#C4, _name:#C5}
#C7 = 2
#C8 = "c"
#C9 = self::Enum {index:#C7, _name:#C8}
#C10 = <self::Enum*>[#C3, #C6, #C9]
}
Constructor coverage from constants:
org-dartlang-testcase:///omitted_break.dart:
- Enum. (from org-dartlang-testcase:///omitted_break.dart:5:6)
- _Enum. (from org-dartlang-sdk:///sdk/lib/core/enum.dart)
- Object. (from org-dartlang-sdk:///sdk/lib/core/object.dart)