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

SI-7436 Varargs awareness for super param aliasing. #2576

Merged
merged 1 commit into from May 23, 2013

Conversation

retronym
Copy link
Member

Don't consider a super class parameter accessor to be
an alias if it is a repeated. Parameter aliases are used
to avoid retaining redundant fields in the subclass; but
that optimization is out of the question here.

Review by @paulp

Don't consider a super class parameter accessor to be
an alias if it is a repeated. Parameter aliases are used
to avoid retaining redundant fields in the subclass; but
that optimization is out of the question here.
@paulp
Copy link
Contributor

paulp commented May 21, 2013

LGTM. I feel like there's another nearly identical ticket for this, but I can't find it so maybe not.

paulp added a commit that referenced this pull request May 23, 2013
SI-7436 Varargs awareness for super param aliasing.
@paulp paulp merged commit 112d4d2 into scala:master May 23, 2013
@retronym
Copy link
Member Author

@Sciss's bug in the comments looks the same, but the main report there appears distinct.

The difference between your patch and mine is that I consider that these aren't aliases at all, whereas you consider them an alias but then discard them when deciding whether the alias can be used to elide the field. That's where I fixed a similar access related bug with the condition localTyper.context.isAccessible(sym, pre, superAccess = true).

Arguably, the access fix is in the wrong place and should be moved. I guess it depends on how you define 'alias'. I don't feel strongly enough to change it, but let me know if you have an opinion.

@paulp
Copy link
Contributor

paulp commented May 25, 2013

I have no strong feelings about paramaccessors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants