Disallow ... without type in function typehints
[hiphop-php.git] / hphp / hack / test / typecheck / typedef17.php
blobdc2f90cbccca2fd56dfca6d82cb88dbaefd4a887
1 <?hh // strict
2 /**
3 * Copyright (c) 2018, Facebook, Inc.
4 * All rights reserved.
6 * This source code is licensed under the MIT license found in the
7 * LICENSE file in the "hack" directory of this source tree.
12 type A<T as string> = vec<T>;
14 function f0<T as string>(A<T> $foo): T {
15 return $foo[0];
18 function f1(vec<string> $x): void {
19 f0($x);
22 function f2(vec<int> $x): void {
23 f0($x);