Updating submodules
[hiphop-php.git] / hphp / hack / test / typecheck / subtype_collection_interfaces_1.php
blobd28739af4ff30916d0659248e36e7e8a729d4700
1 <?hh
2 class B {}
3 class C extends B {}
5 function foo1(varray<B> $x): void {}
6 function test1(varray<C> $x): void { foo1($x); }
8 function foo2(darray<mixed, B> $x): void {}
9 function test2(darray<int, C> $x): void { foo2($x); }
11 function foo3(Traversable<B> $x): void {}
12 function test3(varray<C> $x): void { foo3($x); }
14 function foo4(KeyedTraversable<mixed, B> $x): void {}
15 function test4(darray<int, C> $x): void { foo4($x); }
17 function foo5(Container<B> $x): void {}
18 function test5(varray<C> $x): void { foo5($x); }
20 function foo6(KeyedContainer<arraykey, B> $x): void {}
21 function test6(darray<int, C> $x): void { foo6($x); }
23 function foo7(KeyedContainer<arraykey, B> $x): void {}
24 function test7(darray<int, C> $x): void { foo7($x); }