65335cb4b3
This handles Never, and as a consequence, empty sealed types in exhaustiveness. Since these contain no value, we should not try to exhaust them. This avoid invalid non-exhaustive errors in these cases. Included is handling of a scrutinee with invalid type as Never in the CFE, thus avoid cascading non-exhaustive or unreachable errors. Change-Id: Ife097731bb5399c42bf83f1d77aff773346adfb6 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/293682 Reviewed-by: Paul Berry <paulberry@google.com> Commit-Queue: Johnni Winther <johnniwinther@google.com>