src/lsp/run.bend

bolt@1.24.0.0 · 13 lines · 0 definitions

1# lsp/run: the container; `bolt lsp` runs it. Native only: the JS lane
2# overflows its stack on big messages.
3import Base
4import bolt@1.24.0.0/src/lsp/server.bend as Server
5import bolt@1.24.0.0/src/lsp/transport/stdio.bend as Stdio
6import bolt@1.24.0.0/src/lsp/files/disk.bend as Disk
7import bolt@1.24.0.0/src/lsp/checker/bend.bend as BendChecker
8
9# the server over stdio, reading the disk
10def run() -> IO(Unit):  # noqa: L001 IO entry point
11  do IO<Unit>:
12    h : Stdio.Stdio <- Stdio.open()
13    Server.serve(~Stdio.Stdio, ~Stdio.new(), ~Disk.new(), ~BendChecker.service(), U32.to_nat(4294967295), h, [])