Skip to content

Commit

Permalink
Fix the type argument on the deep flattening spread test.
Browse files Browse the repository at this point in the history
Change-Id: Icba0904c88a18901c0a2d423a8ce7ab7af8413fd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/94941
Reviewed-by: Leaf Petersen <leafp@google.com>
Commit-Queue: Bob Nystrom <rnystrom@google.com>
  • Loading branch information
munificent authored and commit-bot@chromium.org committed Mar 4, 2019
1 parent 62df51c commit b88e6dd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion tests/language_2/spread_collections/const_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ void testList() {

// Does not deep flatten.
Expect.identical(
const <int>[1, 2, <int>[3], 4], const <int>[1, ...<int>[2, <int>[3], 4]]);
const <Object>[1, 2, <int>[3], 4],
const <Object>[1, ...<Object>[2, <int>[3], 4]]);

// Establishes const context.
Expect.identical(const <Symbol>[Symbol("sym")],
Expand Down
3 changes: 2 additions & 1 deletion tests/language_2/spread_collections/spread_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ void testList() {
// Does not deep flatten.
var innerList = <int>[3];
Expect.listEquals(
<int>[1, 2, innerList, 4], <int>[1, ...<int>[2, innerList, 4]]);
<Object>[1, 2, innerList, 4],
<Object>[1, ...<Object>[2, innerList, 4]]);

// Downcast element.
Expect.listEquals(list, <int>[...<num>[1, 2, 3, 4]]);
Expand Down

0 comments on commit b88e6dd

Please sign in to comment.