repo.or.cz
/
hiphop-php.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
No error on use of `unsafe_cast`
[hiphop-php.git]
/
hphp
/
hack
/
test
/
typecheck
/
xhp_attr_7.php
blob
3089544e6371ec7985a0b1dbe2091db86f36ca75
1
<
?hh
// strict
2
class
:
foo
{
3
// Typechecker must consider this nullable
4
attribute
int
x
=
null
;
5
}
6
function
test1
(:
foo
$obj
):
int
{
7
// Typechecker should detect a mismatch here
8
return
$obj
->:
x
;
9
}