Skip to content

Commit 7cadd70

Browse files
rakudramacommit-bot@chromium.org
authored andcommitted
Fix language_2/ct_const_test
Change-Id: Iebb3e40b8835ae5f24afe7ae31117ff24c18aa5e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/108370 Commit-Queue: Stephen Adams <[email protected]> Reviewed-by: Lasse R.H. Nielsen <[email protected]>
1 parent a917043 commit 7cadd70

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/language_2/ct_const_test.dart

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
4-
// All things regarding compile time constant expressions.
4+
5+
// Test of apparent compile-time nature of constant evaluation. Constant Lists,
6+
// Maps and other objects should be identical independent of formation.
57

68
import "package:expect/expect.dart";
79

@@ -70,7 +72,9 @@ class CTConstTest {
7072
Expect.equals(true, identical(l1, l2));
7173

7274
final evenNumbers = const <int>[2, 2 * 2, 2 * 3, 2 * 4, 2 * 5];
73-
Expect.equals(true, !identical(evenNumbers, const [2, 4, 6, 8, 10]));
75+
Expect.equals(true, identical(evenNumbers, const <int>[2, 4, 6, 8, 10]));
76+
Expect.equals(
77+
true, !identical(evenNumbers, const <dynamic>[2, 4, 6, 8, 10]));
7478

7579
final c11dGermany1 = const {"black": 1, "red": 2, "yellow": 3};
7680
Expect.equals(true,

0 commit comments

Comments
 (0)