Prefer Field for class properties in LSP
commit15f5cc2ab4552486b76b7b0fd4270a952ab75150
authorWilfred Hughes <wilfred@fb.com>
Thu, 26 May 2022 18:30:13 +0000 (26 11:30 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Thu, 26 May 2022 18:30:13 +0000 (26 11:30 -0700)
treea3c66edbf13a22d292cdd78185e713e47c5742a7
parentcd88a241d7203328acb918cd61ca768dbc97fa5e
Prefer Field for class properties in LSP

Summary:
VS Code uses 'Field' for what most other languages call properties, and uses 'Property' for the C# notion of "a property with an automatic getter and setter".

For example, the TypeScript LSP uses Field:

{F735551734}

Whereas Hack has a confusing spanner/wrench icon due to using Property for its completion kind:

{F735551749}

Use Field instead for Hack class properties.

Reviewed By: hgoldstein

Differential Revision: D36683640

fbshipit-source-id: 6f75a2e1214e71cbb3fb901353f7c3c8b1bd6df8
hphp/hack/src/client/clientLsp.ml
hphp/hack/test/integration/test_lsp.py