Refresh named labels in the copy of finally body
commit519941637decb7ef7400f2f89769bd62781c83ff
authorVladimir Matveev <vladima@fb.com>
Thu, 22 Jun 2017 21:59:27 +0000 (22 14:59 -0700)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Thu, 22 Jun 2017 22:06:41 +0000 (22 15:06 -0700)
tree9fe9091fb6f163f314791aee1f17e4bd25e2d01a
parent9cc956844120649200135f2c68415cee5b1bc416
Refresh named labels in the copy of finally body

Summary:
Previosly we did not do this which resulted in duplicate label definitions.
Also this diff brings emit a bit closer to hhvm: if try block is empty then we skip emit for try/catch and emit only finally block for try/finally

Reviewed By: oulgen

Differential Revision: D5303501

fbshipit-source-id: a6e58dd2b2c58d86cbfcd491e21dfefd9c1006d3
hphp/hack/src/hhbc/emit_statement.ml
hphp/hack/src/hhbc/label_rewriter.ml
hphp/test/hhcodegen_failing_tests_quick
hphp/test/hhcodegen_failing_tests_zend_tests