Skip to content

Transform/nullarify #122

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 7 commits into from
Apr 15, 2014
Merged

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Apr 14, 2014

Changes to support nullarify transform which inserts () as needed.

odersky added 5 commits April 14, 2014 15:17
Implicit members are TermRefs that should have a prefix corresponding to the object of which they are a member. They used to have the ThisType of their owner before.

`implicits2` provides a way to verify that the change works. It would be good to turn this
into a more robust test at some point.  But it's not high preiority, so I prefer no test to a fragile test.
Stable methods are introduced from getters by inserting () parameters.
This change makes sure that adding () does not lose the members of an
ExprType.

Also, avoid spurious stale symbol errors in loadDenot. When something is not
a SymDenotation, no use retrying in first phase; current would fail immediately.
Factored out denot transformer behavior where the we transform types
in a uniform way into InfoTransformers.
Was an oversight before.
As a denotation need to take the symbol's info *as seen from
the qualifier type*.
@odersky
Copy link
Contributor Author

odersky commented Apr 14, 2014

Review and sheparding by @DarkDimius please. @sjrd please review.

List(new PatternMatcher,
new LazyValTranformContext().transformer,
new Splitter),
List(new Nullarify,
Copy link
Contributor

Choose a reason for hiding this comment

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

What was a reason to create one more group?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's explained in class Nullarify:

override def runsAfterGroupsOf: Set[String] = Set("splitter")
  // assumes idents and selects have symbols; interferes with splitter distribution
  // that's why it's "after group".

@sjrd
Copy link
Member

sjrd commented Apr 15, 2014

That's all for me.

odersky and others added 2 commits April 15, 2014 11:07
DarkDimius added a commit that referenced this pull request Apr 15, 2014
@DarkDimius DarkDimius merged commit fae2c3f into scala:master Apr 15, 2014
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