@@ -510,8 +510,9 @@ let getComplementaryCompletionsForTypedValue ~opens ~allFiles ~scope ~env prefix
510
510
in
511
511
localCompletionsWithOpens @ fileModules
512
512
513
- let getCompletionsForPath ~package ~opens ~allFiles ~pos ~exact ~scope
513
+ let getCompletionsForPath ~debug ~ package ~opens ~allFiles ~pos ~exact ~scope
514
514
~completionContext ~env path =
515
+ if debug then Printf. printf " Path %s\n " (path |> String. concat " ." );
515
516
match path with
516
517
| [] -> []
517
518
| [prefix] ->
@@ -737,7 +738,7 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~allFiles ~pos
737
738
])
738
739
| CPId (path , completionContext ) ->
739
740
path
740
- |> getCompletionsForPath ~package ~opens ~all Files ~pos ~exact
741
+ |> getCompletionsForPath ~debug ~ package ~opens ~all Files ~pos ~exact
741
742
~completion Context ~env ~scope
742
743
| CPApply (cp , labels ) -> (
743
744
match
@@ -784,7 +785,7 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~allFiles ~pos
784
785
| CPField (CPId (path , Module), fieldName ) ->
785
786
(* M.field *)
786
787
path @ [fieldName]
787
- |> getCompletionsForPath ~package ~opens ~all Files ~pos ~exact
788
+ |> getCompletionsForPath ~debug ~ package ~opens ~all Files ~pos ~exact
788
789
~completion Context:Field ~env ~scope
789
790
| CPField (cp , fieldName ) -> (
790
791
let completionsForCtxPath =
@@ -952,7 +953,7 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~allFiles ~pos
952
953
in
953
954
let completions =
954
955
completionPath @ [funNamePrefix]
955
- |> getCompletionsForPath ~completion Context:Value ~exact: false
956
+ |> getCompletionsForPath ~debug ~ completion Context:Value ~exact: false
956
957
~package ~opens ~all Files ~pos ~env ~scope
957
958
in
958
959
let completions =
@@ -1016,8 +1017,8 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~allFiles ~pos
1016
1017
| CJsxPropValue {pathToComponent; propName} -> (
1017
1018
let findTypeOfValue path =
1018
1019
path
1019
- |> getCompletionsForPath ~completion Context:Value ~exact: true ~package
1020
- ~opens ~all Files ~pos ~env ~scope
1020
+ |> getCompletionsForPath ~debug ~ completion Context:Value ~exact: true
1021
+ ~package ~ opens ~all Files ~pos ~env ~scope
1021
1022
|> completionsGetTypeEnv2 ~debug ~full ~opens ~raw Opens ~all Files ~pos
1022
1023
~scope
1023
1024
in
@@ -1031,7 +1032,7 @@ and getCompletionsForContextPath ~debug ~full ~opens ~rawOpens ~allFiles ~pos
1031
1032
let rec digToTypeForCompletion path =
1032
1033
match
1033
1034
path
1034
- |> getCompletionsForPath ~completion Context:Type ~exact: true
1035
+ |> getCompletionsForPath ~debug ~ completion Context:Type ~exact: true
1035
1036
~package ~opens ~all Files ~pos ~env ~scope
1036
1037
with
1037
1038
| {kind = Type {kind = Abstract (Some (p , _ ))} } :: _ ->
@@ -1412,8 +1413,8 @@ let rec processCompletable ~debug ~full ~scope ~env ~pos ~forHover completable =
1412
1413
let allFiles = FileSet. union package.projectFiles package.dependenciesFiles in
1413
1414
let findTypeOfValue path =
1414
1415
path
1415
- |> getCompletionsForPath ~completion Context:Value ~exact: true ~package
1416
- ~opens ~all Files ~pos ~env ~scope
1416
+ |> getCompletionsForPath ~debug ~ completion Context:Value ~exact: true
1417
+ ~package ~ opens ~all Files ~pos ~env ~scope
1417
1418
|> completionsGetTypeEnv2 ~debug ~full ~opens ~raw Opens ~all Files ~pos
1418
1419
~scope
1419
1420
in
0 commit comments