Files
sdk/pkg/front_end/testcases/implicit_const_with_static_fields.dart
T
Dmitry Stefantsov b793c8a387 [fasta] Require explicit handling of all expression kinds in ConstnessEvaluator
Change-Id: I619f4e9e7d606232034d82645e02049b53cb94d5
Reviewed-on: https://dart-review.googlesource.com/49122
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-04-04 11:09:02 +00:00

16 lines
363 B
Dart

// Copyright (c) 2018, 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.
const constTopLevelField = 42;
class C {
const C(x);
static const constField = 87;
}
main() {
C(C.constField);
C(constTopLevelField);
}