Files
sdk/pkg/front_end/testcases/nnbd_mixed/issue42003.dart.weak.expect
T
Johnni Winther f591ad7d88 [cfe] Only perform legacy-to-non-nullable conversion on inferred types
The exempts types for synthesized variables to avoid emitting a warning
on `o?.foo` when `o` is a legacy type.

Closes #42276
Closes #42003

Change-Id: Ideaf099e25c0d50a35a2e704a29aacceb22142b1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151516
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2020-06-18 18:06:46 +00:00

18 lines
485 B
Plaintext

library /*isNonNullableByDefault*/;
import self as self;
import "dart:core" as core;
import "issue42003_lib.dart" as iss;
import "org-dartlang-testcase:///issue42003_lib.dart";
static method main() → dynamic {
let final core::String* #t1 = iss::returnString() in #t1.{core::String::==}(null) ?{core::int?} null : #t1{core::String}.{core::String::length};
}
library;
import self as iss;
import "dart:core" as core;
static method returnString() → core::String*
return "foo";