Skip to content

Show deinit in document symbols #1397

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

Merged
merged 1 commit into from
Jun 3, 2024

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Jun 2, 2024

rdar://128715297

@ahoppen ahoppen requested review from bnbarham and hamishknight June 2, 2024 00:07
@ahoppen ahoppen requested a review from benlangmuir as a code owner June 2, 2024 00:07
@ahoppen
Copy link
Member Author

ahoppen commented Jun 2, 2024

@swift-ci Please test

return record(
node: node,
name: node.deinitKeyword.text,
symbolKind: .null,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kind of weird, but could make constructor?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought about it as well but then felt that constructor is weird because it’s not a constructor… But I don’t have strong opinions here.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO it would be more like a function (assuming that doesn't break any invariants), but also don't feel strongly 🤷

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just checked and VS Code at least uses the same icon for constructor and function, so it’s odd if deinit uses a different icon. clangd uses constructor, so let’s just do that as well.

Screenshot 2024-06-03 at 09 07 41

@ahoppen ahoppen merged commit b9c7438 into swiftlang:main Jun 3, 2024
3 checks passed
@ahoppen ahoppen deleted the deinit-in-document-symbols branch June 3, 2024 15:32
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.

3 participants