// 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. // @dart=2.9 class A { String call(String s) => '$s$s'; } class B { T call(T t) => t; } class C { T call(T t) => t; } test() { A a = A(); List list1 = ['a', 'b', 'c'].map(a.call).toList(); List list2 = ['a', 'b', 'c'].map(a).toList(); B b = B(); List list3 = ['a', 'b', 'c'].map(b.call).toList(); List list4 = ['a', 'b', 'c'].map(b).toList(); C c = C(); List list5 = ['a', 'b', 'c'].map(c.call).toList(); List list6 = ['a', 'b', 'c'].map(c).toList(); } main() {}