I haven't looked this over too much but I'm curious as to why they did this:
<?hh
class MyClass {
const int MyConst = 0;
private string $x = '';
public function increment(int $x): int {
$y = $x + 1;
return $y;
}
}
instead of this: <?hh class MyClass { const MyConst: int = 0; private $x: string = ''; public function increment(int $x): int { $y = $x + 1; return $y; } }
The first seems inconsistent to me. Especially coming from AS3/Haxe where the function return value is indicated in the same manner.