| library; |
| import self as self; |
| import "dart:core" as core; |
| |
| static method test(dynamic o) → core::int { |
| #L1: |
| { |
| core::int #t1 = 1.{core::int::unary-}(){() → core::int}; |
| final synthesized dynamic #0#0 = o; |
| #L2: |
| { |
| { |
| hoisted dynamic a; |
| if(#0#0 is core::List<dynamic> && #0#0{core::List<dynamic>}.{core::List::length}{core::int} =={core::num::==}{(core::Object) → core::bool} #C1 && (let final dynamic #t2 = a = #0#0{core::List<dynamic>}.{core::List::[]}(0){(core::int) → dynamic} in true)) { |
| { |
| return a as{TypeError,ForDynamic} core::int; |
| } |
| } |
| } |
| { |
| if(#C2 =={core::num::==}{(core::Object) → core::bool} #0#0) { |
| { |
| #t1 = 0; |
| break #L2; |
| } |
| } |
| } |
| { |
| if(#C1 =={core::num::==}{(core::Object) → core::bool} #0#0) { |
| { |
| return 1; |
| } |
| } |
| } |
| { |
| if(#C3 =={core::num::==}{(core::Object) → core::bool} #0#0) { |
| #t1 = 0; |
| break #L2; |
| } |
| } |
| { |
| if(#C4 =={core::num::==}{(core::Object) → core::bool} #0#0) { |
| { |
| #t1 = 1; |
| break #L2; |
| } |
| } |
| } |
| { |
| if(#C5 =={core::num::==}{(core::Object) → core::bool} #0#0) { |
| { |
| return 4; |
| } |
| } |
| } |
| { |
| { |
| #t1 = 1; |
| break #L2; |
| } |
| } |
| } |
| switch(#t1) /* dynamic */ { |
| #L3: |
| case #C2: |
| { |
| { |
| return 2; |
| } |
| } |
| #L4: |
| case #C1: |
| default: |
| { |
| { |
| return 1.{core::int::unary-}(){() → core::int}; |
| } |
| } |
| } |
| } |
| } |
| static method main() → dynamic { |
| self::expect(0, self::test(core::_GrowableList::_literal1<core::int>(0))); |
| self::expect(1, self::test(core::_GrowableList::_literal1<core::int>(1))); |
| self::expect(2, self::test(0)); |
| self::expect(1, self::test(1)); |
| self::expect(2, self::test(2)); |
| self::expect(1.{core::int::unary-}(){() → core::int}, self::test(3)); |
| self::expect(4, self::test(4)); |
| self::expect(1.{core::int::unary-}(){() → core::int}, self::test(5)); |
| self::expect(1.{core::int::unary-}(){() → core::int}, self::test(core::_GrowableList::•<dynamic>(0))); |
| } |
| static method expect(dynamic expected, dynamic actual) → dynamic { |
| if(!(expected =={core::Object::==}{(core::Object) → core::bool} actual)) { |
| throw "Expected ${expected}, actual ${actual}"; |
| } |
| } |
| |
| constants { |
| #C1 = 1 |
| #C2 = 0 |
| #C3 = 2 |
| #C4 = 3 |
| #C5 = 4 |
| } |
| |
| Extra constant evaluation status: |
| Evaluated: InstanceInvocation @ org-dartlang-testcase:///switch_with_continue.dart:6:3 -> IntConstant(-1) |
| Evaluated: InstanceInvocation @ org-dartlang-testcase:///switch_with_continue.dart:23:14 -> IntConstant(-1) |
| Evaluated: InstanceInvocation @ org-dartlang-testcase:///switch_with_continue.dart:33:10 -> IntConstant(-1) |
| Evaluated: InstanceInvocation @ org-dartlang-testcase:///switch_with_continue.dart:35:10 -> IntConstant(-1) |
| Evaluated: InstanceInvocation @ org-dartlang-testcase:///switch_with_continue.dart:36:10 -> IntConstant(-1) |
| Extra constant evaluation: evaluated: 63, effectively constant: 5 |