Skip to content

Instantly share code, notes, and snippets.

@HRMsimon
Created December 8, 2015 23:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save HRMsimon/67cd7336061de427c2a0 to your computer and use it in GitHub Desktop.
Save HRMsimon/67cd7336061de427c2a0 to your computer and use it in GitHub Desktop.
test.php:9:10,19: Typing error (Typing[4110])
test.php:3:30,33: This is a nullable type
test.php:9:19,19: It is incompatible with an int
<?hh // strict
function returns_nullable(): ?int {
return null;
}
function use_nullable(): bool {
$value = returns_nullable();
return $value > 1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment