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
Disallow ... without type in function typehints
[hiphop-php.git]
/
hphp
/
hack
/
test
/
typecheck
/
trait_use_aliasing_hack.php
blob
4f5d2cb0de642aebc272d9b68c9fbbf471c3e9a1
1
<
?hh
// strict
2
3
trait HelloTrait
{
4
public
async
function
genHello
():
Awaitable
<
string
> {
5
return
'Hello'
;
6
}
7
}
8
class
HelloClass
{
9
use
HelloTrait
{
10
genHello
as
genHelloTrait
;
11
}
12
13
<<
__Override
>>
14
public
async
function
genHello
():
Awaitable
<
string
> {
15
$parent_str
=
await
$this
->
genHelloTrait
();
16
return
$parent_str
.
' World'
;
17
}
18
}