Allow top level expression statements containing function expressions
commit1751f97e5f03b229bfd6c19cbbaf8ef5e9074423
authorVladimir Matveev <vladima@fb.com>
Mon, 9 Oct 2017 16:25:29 +0000 (9 09:25 -0700)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Mon, 9 Oct 2017 16:42:07 +0000 (9 09:42 -0700)
treebda60be0d9f204c1209fd960e57a75c3d9031cfd
parent0e4710bb27969e6cbd02ae3d97fc8ad39fb186fa
Allow top level expression statements containing function expressions

Summary:
```lang=php
function () {};
```

is a legal PHP syntax and it is parsed as expression statement that contains anonymous function - update FFP to handle this case.

Reviewed By: oulgen

Differential Revision: D5981239

fbshipit-source-id: be105372a17fe720c504f4cd20ee631b2e5b4d90
hphp/hack/src/parser/full_fidelity_declaration_parser.ml
hphp/hack/src/parser/full_fidelity_statement_parser.ml
hphp/hack/src/parser/full_fidelity_statement_parser_type.ml
hphp/test/hhcodegen_failing_tests_quick
hphp/test/hhcodegen_failing_tests_slow