mirror of
https://github.com/dart-lang/sdk
synced 2024-09-15 23:19:47 +00:00
[ddc] Merge modular/issue37523 test into modular/nested_constants test
Change-Id: I5d60de4468f8608fe275fccd2e4f833a8bcfb89d Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112340 Reviewed-by: Nicholas Shahan <nshahan@google.com> Commit-Queue: Johnni Winther <johnniwinther@google.com>
This commit is contained in:
parent
ea313da021
commit
9ec8d9ff25
|
@ -1,15 +0,0 @@
|
|||
// Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
|
||||
// for details. All rights reserved. Use of this source code is governed by a
|
||||
// BSD-style license that can be found in the LICENSE file.
|
||||
|
||||
class B {
|
||||
const B();
|
||||
}
|
||||
|
||||
class A {
|
||||
final B b;
|
||||
const A(this.b);
|
||||
}
|
||||
|
||||
const ab = A(B());
|
||||
const b = B();
|
|
@ -1,15 +0,0 @@
|
|||
// Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
|
||||
// for details. All rights reserved. Use of this source code is governed by a
|
||||
// BSD-style license that can be found in the LICENSE file.
|
||||
|
||||
import 'package:expect/expect.dart';
|
||||
|
||||
import 'def.dart';
|
||||
|
||||
main() {
|
||||
const v1 = A(B());
|
||||
const v2 = ab;
|
||||
const v3 = A(b);
|
||||
Expect.equals(v1, v2);
|
||||
Expect.equals(v2, v3);
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
# Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
|
||||
# for details. All rights reserved. Use of this source code is governed by a
|
||||
# BSD-style license that can be found in the LICENSE file.
|
||||
|
||||
dependencies:
|
||||
main: [def, expect]
|
||||
flags:
|
||||
- constant-update-2018
|
|
@ -12,4 +12,10 @@ const c3 = A(b);
|
|||
main() {
|
||||
Expect.equals(c1, c2);
|
||||
Expect.equals(c2, c3);
|
||||
|
||||
const v1 = A(B());
|
||||
const v2 = ab;
|
||||
const v3 = A(b);
|
||||
Expect.equals(v1, v2);
|
||||
Expect.equals(v2, v3);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue