No error on use of `unsafe_cast`
[hiphop-php.git] / hphp / hack / test / typecheck / anon14.php
blobac97f77ca2d79221c2c7f4034be03126d3dc28c4
1 <?hh // strict
2 /**
3 * Copyright (c) 2014, 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 function show<T>(T $x): void {}
14 function test(): void {
15 $v = Vector {
16 function($x) {
17 return $x;
20 $v[0] = function($x) use ($v) {
21 return $v[0]($x);
23 $v[0](1);