Skip to content

v0.1.0-rc.3: remove idl dependency in src/ulsp/mapper

Latest

Choose a tag to compare

@zerunz zerunz released this 21 Oct 17:05
52c0f65

Move all functions under src/ulsp/mapper that touch proto code into a
separate sub-package, src/ulsp/mapper/idl.
This way:
src/ulsp/mapper only contains logic for LSP, JSON-RPC, and general
mapping.
src/ulsp/mapper/idl contains the parts that translate between internal
models and protobuf messages.
When a controller imports mapper, no proto code is compiled in.
Only code that explicitly imports mapper/idl will depend on the
generated .pb.go files.
So that it won't cause proto: duplicate proto type registered: error
log when importing github.com/uber/scip-lsp/src/ulsp/controller/scip
due to importing two versions of the same proto file that may conflict
with each other