Files
sdk/tests/language/main/main_test.dart
T
Johnni Winther 4c29f26fc6 [cfe] Report errors in invalid main declarations
Closes #43554
Closes #43556
Closes #43558

Change-Id: Ib3e2b891473f07bad7b4a373152be684095619b8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165904
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2020-10-05 14:37:33 +00:00

24 lines
551 B
Dart

// Copyright (c) 2014, 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.
main(
a // //# 01: ok
a, b // //# 02: ok
a, b, c // //# 03: compile-time error
a, b, {c} //# 04: ok
a, b, [c] //# 05: ok
[a] // //# 20: ok
a, [b] // //# 21: ok
[a, b] // //# 22: ok
{a} // //# 41: ok
a, {b} // //# 42: ok
{a, b} // //# 43: ok
[a, b, c] //# 44: ok
{a, b, c} //# 45: ok
) {}