blob: 6606fc4dc9b3c3598f214a61e8f2502a6f657011 [file] [log] [blame]
// Copyright (c) 2020, 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.
// SharedObjects=ffi_test_functions
import 'package:expect/expect.dart';
import 'dylib_utils.dart';
int foo<T>(int i, T j, Type t) {
Expect.equals(T, t);
return i + 2;
main() {
final x = foo(1, 0.0, double);
final y = foo(2, 0, int);
Expect.equals(3, x);
Expect.equals(4, y);