Skip to content

Commit dbdece0

Browse files
Wilfredgithub-actions[bot]
authored andcommitted
Update guides/hack from HHVM repository
1 parent cedf317 commit dbdece0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

guides/hack/55-expression-trees/10-splicing.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Expression trees support "splicing", where you insert one expression tree into a
33
```hack
44
<<file:__EnableUnstableFeatures('expression_trees')>>
55
6-
function splicing_example(bool $b): ExprTree<ExampleDsl, ExampleDsl::TAst, ExampleString> {
6+
function splicing_example(bool $b): ExampleExpression<ExampleString> {
77
$name = $b ? ExampleDsl`"world"` : ExampleDsl`"universe"`;
88
return ExampleDsl`"Hello, ".${$name}."!"`;
99
}
@@ -16,7 +16,7 @@ The above example is equivalent to this:
1616
```hack
1717
<<file:__EnableUnstableFeatures('expression_trees')>>
1818
19-
function splicing_example2(bool $b): ExprTree<ExampleDsl, ExampleDsl::TAst, ExampleString> {
19+
function splicing_example2(bool $b): ExampleExpression<ExampleString> {
2020
return $b ? ExampleDsl`"Hello, "."world"."!"` : ExampleDsl`"Hello, "."universe"."!"`;
2121
}
2222
```

0 commit comments

Comments
 (0)