Ban using await on the right of a pipe operator
commit520125768f700e735dd62682fb66b2c9f8821efd
authorKendall Hopkins <kendallhopkins@fb.com>
Sat, 18 May 2019 20:52:04 +0000 (18 13:52 -0700)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Sat, 18 May 2019 20:56:36 +0000 (18 13:56 -0700)
treed4945bdb1ffd888864528350e1204bd987bf8dd4
parentd9e49a3856a4d846fd86a11de75eeee10e228992
Ban using await on the right of a pipe operator

Summary: Initially I had some complex logic to allow await on both sides of a pipe operator, but due to the way lifting is implemented, this didn't really ever work properly (would give bogus complaint about $$ outside of |> expression). I'm just going to ban it for now and we can re-evaluate allowing it in the future.

Reviewed By: vladima

Differential Revision: D15395949

fbshipit-source-id: d73f6c9eb98ffffd57853e167ec5bce27684d710
hphp/hack/src/parser/full_fidelity_parser_errors.ml
hphp/hack/test/full_fidelity/cases/await_as_an_expression/await_as_an_expression_simple.php
hphp/hack/test/full_fidelity/cases/await_as_an_expression/await_as_an_expression_simple.php.sexp.exp
hphp/hack/test/full_fidelity/cases/await_as_an_expression/error/await_as_an_expression_invalid_location.php
hphp/hack/test/full_fidelity/cases/await_as_an_expression/error/await_as_an_expression_invalid_location.php.errors.exp
hphp/hack/test/full_fidelity/cases/await_as_an_expression/error/await_as_an_expression_invalid_location.php.sexp.exp