2 * Copyright (c) 2017, Facebook, Inc.
5 * This source code is licensed under the BSD-style license found in the
6 * LICENSE file in the "hack" directory of this source tree. An additional grant
7 * of patent rights can be found in the PATENTS file in the same directory.
11 (* Details about functions to be added in json output *)
12 type func_param_result
= {
15 param_variadic
: bool;
18 type func_details_result
= {
19 params
: func_param_result list
;
24 type autocomplete_kind
=
39 (* Results ready to be displayed to the user *)
40 type complete_autocomplete_result
= {
41 res_pos
: Pos.absolute
;
44 res_kind
: autocomplete_kind
;
45 func_details
: func_details_result
option;
48 (* Results that still need a typing environment to convert ty information
50 type partial_autocomplete_result
= {
51 ty
: Typing_defs.phase_ty
;
53 kind_
: autocomplete_kind
;
56 type autocomplete_result
=
57 | Partial
of partial_autocomplete_result
58 | Complete
of complete_autocomplete_result
60 (* The type returned to the client *)
62 completions
: complete_autocomplete_result list
;
67 type result
= complete_autocomplete_result list
69 type legacy_autocomplete_context
= {
70 is_xhp_classname
: bool;
71 is_instance_member
: bool;