Skip to content

SI-8841 report named arg / assignment ambiguity also in silent mode.#4195

Merged
adriaanm merged 1 commit intoscala:2.11.xfrom
lrytz:t8841
Feb 13, 2015
Merged

SI-8841 report named arg / assignment ambiguity also in silent mode.#4195
adriaanm merged 1 commit intoscala:2.11.xfrom
lrytz:t8841

Conversation

@lrytz
Copy link
Member

@lrytz lrytz commented Dec 11, 2014

For local definitions (eg. in a block that is an argument of a method
call), the type completer may have a silent context. A CyclicReference
is then not thrown but transformed into a NormalTypeError. When
deciding if 'x = e' is an assignment or a named arg, we need to report
cyclic references, but not other type errors. In the above case, the
cyclic reference was not reported.

Also makes sure that warnings are printed after typing argument
expressions.

@scala-jenkins scala-jenkins added this to the 2.11.6 milestone Dec 11, 2014
@som-snytt
Copy link
Contributor

It must be Thursday. Nicely scrounged.

For local definitions (eg. in a block that is an argument of a method
call), the type completer may have a silent context. A CyclicReference
is then not thrown but transformed into a NormalTypeError. When
deciding if 'x = e' is an assignment or a named arg, we need to report
cyclic references, but not other type errors. In the above case, the
cyclic reference was not reported.

Also makes sure that warnings are printed after typing argument
expressions.
@lrytz
Copy link
Member Author

lrytz commented Dec 12, 2014

Review by @retronym - note the change in t8463.check and the existing comment in t8463.scala

@adriaanm
Copy link
Contributor

ping @retronym

@adriaanm
Copy link
Contributor

I'll merge the last 2.11.5 PRs my Monday morning, if they have been LGTM'ed by then.

@som-snytt
Copy link
Contributor

At midnight on xmas eve, Santa brings lgtms to all the good girls and boys. His army of elf coders is hard at work until then. In fact, they were responsible for the Sony hack. A disagreement over Santa's discount on PS4s.

@adriaanm
Copy link
Contributor

Is that why he went with the mach-o coders this year? I hear they're indifferent to discounts.

@adriaanm
Copy link
Contributor

In principle, this LGTM, but I'd rather not merge typer changes right before the elves take over. Moved to 2.11.6.

@adriaanm adriaanm modified the milestones: 2.11.6, 2.11.5 Dec 23, 2014
@retronym
Copy link
Member

LGTM

adriaanm added a commit that referenced this pull request Feb 13, 2015
SI-8841 report named arg / assignment ambiguity also in silent mode.
@adriaanm adriaanm merged commit 4554a10 into scala:2.11.x Feb 13, 2015
@lrytz lrytz deleted the t8841 branch March 30, 2015 09:31
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.

5 participants