dart-sdk/tests/language/regress/regress46165_test.dart
Regis Crelier 7014f03aad [VM/runtime] Fix type test: a closure is T, when T is instantiated to Object.
Fixes https://github.com/dart-lang/sdk/issues/46165

TEST=added regression test

Change-Id: I3016f60560b00f077d5ef55a0b23ccfb7dbf0836
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/201863
Reviewed-by: Liam Appelbe <liama@google.com>
Commit-Queue: Régis Crelier <regis@google.com>
2021-06-01 20:25:55 +00:00

11 lines
314 B
Dart

// Copyright (c) 2021, 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.
void main() {
final l = <Object>[];
l.add((String x, StringBuffer y) {
print(x);
});
}