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

scala213Source3 - allow infix op after NL #2740

Merged
merged 1 commit into from Apr 26, 2022
Merged

Conversation

dos65
Copy link
Member

@dos65 dos65 commented Apr 26, 2022

Original PR in compiler - scala/scala#8419
Fixes #2739.

Copy link
Collaborator

@tgodzik tgodzik left a comment

Choose a reason for hiding this comment

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

So minor comments, but otherwise LGTM! Thanks for looking into this!

@@ -360,7 +360,7 @@ private[parsers] class LazyTokenIterator private (
case _: RegionIndent | _: RegionIndentEnum => true
case x: RegionParen => x.canProduceLF
case _ => false
}
} && !next.isLeadingInfixOperator
Copy link
Collaborator

Choose a reason for hiding this comment

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

Was it a bug in Scala 3 implementation?

Copy link
Member Author

Choose a reason for hiding this comment

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

No, for scala3 NL wasn't produced but it's in a different branch(if(dialect.allowsSingnificantIndentation) {...}).

@dos65 dos65 merged commit c927450 into scalameta:main Apr 26, 2022
@dos65 dos65 deleted the fix_2739 branch April 26, 2022 15:35
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.

"failed to generate semanticdb for" error for Scala 3 syntax in Scala 2 (with -Xsource:3 enabled)
3 participants