Skip to content

Fix tests on case-insensitive filesystems #4120

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

Conversation

nicolasstucki
Copy link
Contributor

No description provided.

smarter
smarter previously approved these changes Mar 15, 2018
}
checkName(claszSymbol)
if (int.symHelper(claszSymbol).isTopLevelModuleClass)
Copy link
Member

Choose a reason for hiding this comment

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

I don't think this should be limited to top-level modules, the same problem exists for inner modules no?

@nicolasstucki nicolasstucki force-pushed the fix-FromTastTests-with-name-issues branch 2 times, most recently from 7ba1669 to 6e9e68e Compare March 16, 2018 07:46
@allanrenucci
Copy link
Contributor

@nicolasstucki Can you fix #4166 as part of this PR?

@nicolasstucki nicolasstucki force-pushed the fix-FromTastTests-with-name-issues branch from 6e9e68e to 7a0cfc7 Compare March 23, 2018 15:48
@nicolasstucki
Copy link
Contributor Author

#4166 is already fixed by this PR

@nicolasstucki nicolasstucki force-pushed the fix-FromTastTests-with-name-issues branch from 20aacf2 to 5a90545 Compare March 23, 2018 18:50
Copy link
Contributor

@biboudis biboudis left a comment

Choose a reason for hiding this comment

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

Looks good. Good to know about the effectiveName!

@nicolasstucki nicolasstucki merged commit 4a257df into scala:master Mar 26, 2018
@Blaisorblade Blaisorblade deleted the fix-FromTastTests-with-name-issues branch March 26, 2018 20:57

object Outer {
class X // error
object x
Copy link
Contributor

Choose a reason for hiding this comment

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

@nicolasstucki Why is this not allowed? It is only an issue when class X and object x are top level, right? Scalac does not complain

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Those classes will emit Outer$X.class and Outer$x.class which may conflict.

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think so. I think Outer$x$.class will be emitted. So there is no conflict. I think it is only an issue for top level objects

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, the object will generate Outer$x$.class but is the class needs a companion object it will generate Outer$X$.class which causes the conflict.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That would happen with

object Outer {
  case class X()
  object x
}

or any other class that generates the module class for it.

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.

4 participants