c5fb584a75
I discovered recently that when we implemented the "patterns" feature, we got the pattern type schema for cast patterns wrong--it was specified to be `_`, but what was actually implemented was `Object?`. I've filed a breaking change request to address that: https://github.com/dart-lang/sdk/issues/54640. In the course of prototyping a fix, I was surprised to find that no language tests or co19 tests were affected; it appears that we don't have adequate test coverage of pattern type schemas. This CL addresses the lack of test coverage by adding a language test. The test case for cast patterns is currently commented out, pending resolution of the breaking change request; after the breaking change lands, I will update the test accordingly. Change-Id: I0d27fd8ac65f16d21a8597586e6f76fd9a5ba86e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/346621 Commit-Queue: Paul Berry <paulberry@google.com> Reviewed-by: Bob Nystrom <rnystrom@google.com>