Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove dependency on uuid #576

Closed
wants to merge 1 commit into from
Closed

Conversation

SquidDev
Copy link
Contributor

While the language server specification uses a UUID for dynamic registration of capabilities, it only has to be a unique id. This change removes the UUID dependency, replacing it with a home-grown random id generator.

The main motivation here is I'm trying to compile LSP (or rather, a program using it) to WASM. The UUID library pulls in a lot of superfluous dependencies (e.g. network-info and entropy) that don't compile with the wasm32-wasm version of GHC, hence trying to remove them.

@michaelpj
Copy link
Collaborator

This seems like a good idea. I think we could in fact do this even more simply. It just has to be a unique ID, so it can just be an incrementing integer! We in fact already have an id-counter that we use for request IDs, I think it sounds like we could just pull an id from that for registrations as well.

@michaelpj
Copy link
Collaborator

I did that here: #578

@SquidDev
Copy link
Contributor Author

Thank you!

@SquidDev SquidDev closed this May 17, 2024
@SquidDev SquidDev deleted the remove-uuid branch May 17, 2024 14:39
@soulomoon
Copy link
Collaborator

great it might help hls to use multi-repl which need cable 3.12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants