-
Notifications
You must be signed in to change notification settings - Fork 80
Add SymbolRelation class with roles and symbols #30
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By using these changes with sourcekit-lsp, I am able to get the containerName of symbols and incorrect SymbolKind values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking pretty good. Thanks for working on this! Specific feedback inline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can see how this looks from the SourceKit-LSP side in my branch here
7771960
to
f8a8ee8
Compare
public final class SymbolRelation { | ||
let value: indexstoredb_symbol_relation_t | ||
|
||
public lazy var roles = SymbolRole(rawValue: indexstoredb_symbol_relation_get_roles(value)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add type annotations (: SymbolRole
) to any class/struct properties. It makes the API more explicit and can improve compile times.
bb1df14
to
1de6594
Compare
Thanks! I think the type annotation for |
Add IndexSymbolKind enum Add kind property in Symbol Add forEachRelation of occurrence function
1de6594
to
31dadcd
Compare
@swift-ci please test |
Add kind property to Symbol
Add forEachRelation of occurrence function
Based on discussions in workspace/symbol PR in apple/sourcekit-lsp.