mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 04:27:17 +00:00
46ceec41d2
Change-Id: I0cfd2ad9e59c985f632d7038a64d903f6b472dd1 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/199480 Auto-Submit: Lasse R.H. Nielsen <lrn@google.com> Commit-Queue: Lasse R.H. Nielsen <lrn@google.com> Reviewed-by: Erik Ernst <eernst@google.com>
20 lines
421 B
Dart
20 lines
421 B
Dart
// 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.
|
|
|
|
|
|
import 'package:expect/expect.dart';
|
|
|
|
class C<X extends num> {
|
|
C(Type t) {
|
|
Expect.equals(t, X);
|
|
}
|
|
}
|
|
|
|
typedef T<X extends int> = C<X>;
|
|
|
|
void main() {
|
|
T<int> x1 = T(int);
|
|
C<int> x2 = T(int);
|
|
}
|