Skip to content

Commit baa2194

Browse files
committed
debug
1 parent ef94d47 commit baa2194

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

analysis/src/Commands.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ let hover ~path ~line ~col ~currentFile ~debug =
3636
| Some ({file} as full) -> (
3737
match References.getLocItem ~full ~line ~col with
3838
| None -> (
39+
if debug then
40+
Printf.printf
41+
"Nothing at that position. Now trying to use completion.\n";
3942
let completions =
4043
getCompletions ~debug ~path ~pos:(line, col) ~currentFile
4144
~forHover:true

analysis/tests/src/expected/Completion.res.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1345,6 +1345,7 @@ Completable: Cpath Value[this]
13451345
}]
13461346

13471347
Hover tests/src/Completion.res 346:14
1348+
Nothing at that position. Now trying to use completion.
13481349
posCursor:[346:14] posNoWhite:[346:13] Found expr:[346:9->346:23]
13491350
JSX <div:[346:9->346:12] name[346:13->346:17]=...[346:18->346:20]> _children:346:21
13501351
Completable: Cjsx([div], name, [name])

analysis/tests/src/expected/Fragment.res.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ Hover tests/src/Fragment.res 6:19
22
{"contents": "```rescript\nReact.component<{\"children\": React.element}>\n```\n\n```rescript\ntype component<'props> = componentLike<'props, element>\n```"}
33

44
Hover tests/src/Fragment.res 9:56
5+
Nothing at that position. Now trying to use completion.
56
posCursor:[9:56] posNoWhite:[9:55] Found expr:[9:10->9:67]
67
Pexp_construct :::[9:13->9:67] [9:13->9:67]
78
posCursor:[9:56] posNoWhite:[9:55] Found expr:[9:13->9:67]

0 commit comments

Comments
 (0)