ac9b4aab8d
Follow-up to https://dart-review.googlesource.com/c/sdk/+/190022 Change-Id: Id42336216267dcbf481ae6e111177e6296ea6779 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/190881 Reviewed-by: Brian Wilkerson <brianwilkerson@google.com> Reviewed-by: Johnni Winther <johnniwinther@google.com> Commit-Queue: Jens Johansen <jensj@google.com>
13 lines
433 B
Dart
13 lines
433 B
Dart
// 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.
|
|
|
|
/// Legacy compound literal syntax that should go away.
|
|
|
|
main() {
|
|
new List<int>[1, 2];
|
|
//^^^^^^^^
|
|
// [analyzer] SYNTACTIC_ERROR.LITERAL_WITH_CLASS_AND_NEW
|
|
// [cfe] A list literal can't be prefixed by 'new List'.
|
|
}
|