Skip to content

Method field cleanup #15691

New issue

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

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

Already on GitHub? # to your account

Merged
merged 2 commits into from
Jul 16, 2014
Merged

Method field cleanup #15691

merged 2 commits into from
Jul 16, 2014

Conversation

jbclements
Copy link
Contributor

This patch applies the excellent suggestion of @pnkfelix to group the helper methods for method field access into a Trait, making the code much more readable, and much more similar to the way it was before.

please note the snapshot-waiting unpleasantness. I'm
unable to use the traditional #[cfg(stage0)] mechanism
to swap the new style in for later compiler stages,
because macros invocations in method positions cause
the parser to choke before cfg can strip it out.

Parenthetical note: this problem wouldn't arise with
an interleaved parsing/expansion....
Per @pnkfelix 's suggestion, using a trait to make these
field accesses more readable (and vastly more similar
to the original code.

oops fix new ast_map fix
bors added a commit that referenced this pull request Jul 16, 2014
…ichton

This patch applies the excellent suggestion of @pnkfelix to group the helper methods for method field access into a Trait, making the code much more readable, and much more similar to the way it was before.
@bors bors closed this Jul 16, 2014
@bors bors merged commit ca05828 into rust-lang:master Jul 16, 2014
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 13, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants