Error on self::class on non final classes
[hiphop-php.git] / hphp / hack / test / typecheck / aktuple / array_append.php
blob1fd42159d2ce7f3f9d0daf280d216fb6f22bc2e2
1 <?hh //strict
3 /* For now, we don't grow tuple-like arrays - appending to them just downgrades
4 * them to vector-like arrays */
6 enum E : int { A = 2; };
8 function expectArrayAK(array<arraykey> $a):void { }
10 function test(): void {
11 $a = varray[4, 'aaa'];
12 $a[] = E::A;
13 expectArrayAK($a);
15 $a = Vector { varray[4, 'aaa'] };
16 $a[0][] = E::A;