Use XPC's data type instead of string to pass the LSP value from Clangd. This will make it easier to use from sourcekit-lsp (https://github.com/apple/sourcekit-lsp/pull/112), where I will be able to drop a conversion between Data and String.
Details
Details
Diff Detail
Diff Detail
- Repository
- rCTE Clang Tools Extra
Event Timeline
Comment Actions
I'd add a test with non-empty non-LSP dictionary to specifically test that we're ignoring the content. I like const-correctness but that's up to you. Otherwise LGTM.
clang-tools-extra/clangd/unittests/xpc/ConversionTests.cpp | ||
---|---|---|
34 | We should also test something like const char* key = "NotAnLSP"; const char* value = "Foo"; xpc_object_t EmptyDict = xpc_dictionary_create(&key, &value, 1); | |
clang-tools-extra/clangd/xpc/Conversion.cpp | ||
22–23 | Nit - const std::string? | |
29–36 | Nit -const size_t and const char * const? |
We should also test something like