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

Migrate Declaration to newer property style, class-ify ClassDefinition #859

Merged
merged 2 commits into from
Sep 29, 2021
Merged

Migrate Declaration to newer property style, class-ify ClassDefinition #859

merged 2 commits into from
Sep 29, 2021

Conversation

jonmeow
Copy link
Contributor

@jonmeow jonmeow commented Sep 28, 2021

No description provided.

@jonmeow jonmeow requested a review from a team as a code owner September 28, 2021 17:45
@google-cla google-cla bot added the cla: yes PR meets CLA requirements according to bot. label Sep 28, 2021
// Returns the enumerator corresponding to the most-derived type of this
// object.
auto Tag() const -> Kind { return tag; }
auto tag() const -> Kind { return tag_; }
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we call this kind instead? That's what I wanted to call these methods originally, if not for the name collision with the Kind type.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done, #860 covers this but may as well reduce merge conflicts here.

Comment on lines +124 to +125
auto alternatives() const -> llvm::ArrayRef<Alternative> {
return alternatives_;
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this have a mutable overload?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

My preference is to do a mutable overload on an as-needed basis. I expect one to be added, it just didn't need one as of yet, I assume because code wasn't implemented to need it.

@jonmeow jonmeow merged commit 47843b1 into carbon-language:trunk Sep 29, 2021
@jonmeow jonmeow deleted the classdef-class branch September 29, 2021 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes PR meets CLA requirements according to bot.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants