Error on self::class on non final classes
[hiphop-php.git] / hphp / hack / test / typecheck / test_to_sort_typing1.php
blob4d7ec1f8dcde63fc1a4141bcc05d5d1902181a38
1 <?hh // partial
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.
18 function f($y, $z){
19 $y = $y . $z;
20 $z[0] = 'dd' + 1;
21 return $y;
26 function g($x) {
27 if (true) {
28 $x = array('d' => 'f');
29 return $x;
31 $x['dd'] = 'dd' + $x['dd'];
32 return $x;
39 function g($x) {
40 $x = array('d' => 0);
41 $x['dd'] = 'dd' + $x['dd'];
42 return $x;
48 function extended_friend_cachekey_scb_used_apps($update_params) {
49 $x = $update_params[0];
50 $y = $update_params + 1;
54 class X {
56 public function g(){
57 $y = array();
58 $x = 0;
59 return $x[1];