Improve error messages for bad method visibility (#8961)nightly-2022.02.02
commitc6a786d0a809a7eb3a827be6981787803242bb7b
authorIan Hoffman <ianhoffman10@gmail.com>
Wed, 2 Feb 2022 02:15:16 +0000 (1 18:15 -0800)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Wed, 2 Feb 2022 02:16:54 +0000 (1 18:16 -0800)
tree9956761dd3738c8d93fe7b24254dff68f6869a20
parent670d9e705795dc4c0d6c795fd19b931426278db2
Improve error messages for bad method visibility (#8961)

Summary:
Closes https://github.com/facebook/hhvm/issues/8959

The biggest trouble I ran into working on this was getting my dev environment configured. I built HHVM in a docker container using docker-compose and mutagen to handle file-syncing with the container. This mostly worked, except for the files generated by `review.sh`: I had to manually copy them out of the container for some reason. Not sure why they didn't sync to the host automatically.

Just curious - what setup do people at FB use for Hack development? Do y'all build locally? And if you use docker or some other remote setup, do you sync VSCode (or some other IDE?) to an LSP running there?

I should probably take these questions over to Slack.

Pull Request resolved: https://github.com/facebook/hhvm/pull/8961

Reviewed By: shayne-fletcher

Differential Revision: D33857025

Pulled By: Wilfred

fbshipit-source-id: a8d0fc932ff2df719d9b9103b77aa2150419248b
25 files changed:
hphp/hack/src/server/autocompleteService.ml
hphp/hack/src/server/serverBigCode.ml
hphp/hack/src/typing/tast_env.mli
hphp/hack/src/typing/typing.ml
hphp/hack/src/typing/typing_object_get.ml
hphp/hack/src/typing/typing_visibility.ml
hphp/hack/src/typing/typing_visibility.mli
hphp/hack/test/fanout/class_method_change_visibility.php.incr_no_old_decls.exp
hphp/hack/test/fanout/class_method_change_visibility.php.incr_old_decl.exp
hphp/hack/test/fanout/class_method_change_visibility.php.saved_state.exp
hphp/hack/test/typecheck/ctor_privacy.php.exp
hphp/hack/test/typecheck/expression_trees/instance_method_private.php.exp
hphp/hack/test/typecheck/expression_trees/instance_method_protected.php.exp
hphp/hack/test/typecheck/function_pointer/class_const_visibility2.php.exp
hphp/hack/test/typecheck/inst_meth7.php.exp
hphp/hack/test/typecheck/instance_method_visibility.php [new file with mode: 0644]
hphp/hack/test/typecheck/instance_method_visibility.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/instance_property_visibility.php [new file with mode: 0644]
hphp/hack/test/typecheck/instance_property_visibility.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/lsb_property_visibility.php [new file with mode: 0644]
hphp/hack/test/typecheck/lsb_property_visibility.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/static_method_visibility.php [new file with mode: 0644]
hphp/hack/test/typecheck/static_method_visibility.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/static_property_visibility.php [new file with mode: 0644]
hphp/hack/test/typecheck/static_property_visibility.php.exp [new file with mode: 0644]