Skip to content

Commit 9ee09d4

Browse files
jamesjwufredemmott
authored andcommitted
Don't crash on inlined definitions, raise error instead
Summary: Why Reviewed By: oulgen, dabek Differential Revision: D8383845
1 parent 05f97eb commit 9ee09d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hphp/hack/src/naming/naming.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1873,7 +1873,7 @@ module Make (GetLocals : GetLocals) = struct
18731873
| Foreach (e, aw, ae, b)-> foreach_stmt env e aw ae b
18741874
| Try (b, cl, fb) -> try_stmt env st b cl fb
18751875
| Def_inline _ ->
1876-
failwith "Naming of inlined definitions not (yet) supported."
1876+
Errors.experimental_feature p "inlined definitions"; N.Expr (p, N.Any)
18771877
| Expr (cp, Call ((p, Id (fp, fn)), hl, el, uel))
18781878
when fn = SN.SpecialFunctions.invariant ->
18791879
(* invariant is subject to a source-code transform in the HHVM

0 commit comments

Comments
 (0)