3ffde1e5ed
Closes #56138 Change-Id: I0bb24b0de3178e3a565b300cb7b9e1dee6c21e80 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/396803 Reviewed-by: Jens Johansen <jensj@google.com> Commit-Queue: Johnni Winther <johnniwinther@google.com>
20 lines
454 B
Plaintext
20 lines
454 B
Plaintext
library;
|
|
import self as self;
|
|
import "dart:core" as core;
|
|
|
|
static method main() → void {
|
|
try {
|
|
has-declared-initializer core::Object? b;
|
|
{
|
|
final synthesized Never #0#0 = throw <core::int, core::int>{42: 42};
|
|
if(!#0#0)
|
|
throw{for-error-handling} new core::StateError::•("Pattern matching error");
|
|
}
|
|
}
|
|
on core::Object catch(final core::Object e) {
|
|
core::print(e);
|
|
return;
|
|
}
|
|
throw "Missing exception";
|
|
}
|