Skip to content

Commit 430bfe9

Browse files
committed
Add example of local open and complete.
1 parent 88784a6 commit 430bfe9

File tree

2 files changed

+28
-1
lines changed

2 files changed

+28
-1
lines changed

analysis/tests/src/Completion.res

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,4 +383,11 @@ let _ = x =>
383383
// ^com
384384

385385
// let _ = `${funRecord.}`
386-
// ^com
386+
// ^com
387+
388+
let _ = _ => {
389+
open Js
390+
// []->ma
391+
// ^com
392+
()
393+
}

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

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1488,3 +1488,23 @@ Completable: Cpath Value[funRecord].""
14881488
"documentation": null
14891489
}]
14901490

1491+
Complete tests/src/Completion.res 389:12
1492+
posCursor:[389:12] posNoWhite:[389:11] Found expr:[387:8->392:1]
1493+
posCursor:[389:12] posNoWhite:[389:11] Found expr:[388:2->391:4]
1494+
posCursor:[389:12] posNoWhite:[389:11] Found expr:[389:6->391:4]
1495+
posCursor:[389:12] posNoWhite:[389:11] Found expr:[389:6->389:12]
1496+
Completable: Cpath array->ma
1497+
[{
1498+
"label": "Js.Array2.mapi",
1499+
"kind": 12,
1500+
"tags": [],
1501+
"detail": "(t<'a>, ('a, int) => 'b) => t<'b>",
1502+
"documentation": null
1503+
}, {
1504+
"label": "Js.Array2.map",
1505+
"kind": 12,
1506+
"tags": [],
1507+
"detail": "(t<'a>, 'a => 'b) => t<'b>",
1508+
"documentation": null
1509+
}]
1510+

0 commit comments

Comments
 (0)