Skip to content

Commit

Permalink
Add failing tests from issue scalameta#1756
Browse files Browse the repository at this point in the history
  • Loading branch information
kitbellew committed Mar 1, 2020
1 parent 0eaffb2 commit 2e574b4
Showing 1 changed file with 60 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -185,3 +185,63 @@ F.runAsync(stream.compile.toVector) {
def old = foo.map { a => b: SomeType => blah() }
>>>
def old = foo.map { a => b: SomeType => blah() }
<<< #1756 val within lambda
object a {
childContext.onDone { _ =>
val _ = self.withChildren(_.remove(childContext))
}
}
>>>
test does not parse
object a {
childContext.onDone(_ => val _ = self.withChildren(_.remove(childContext)))
}
<<< #1756 def within lambda
object a {
childContext.onDone { _ =>
def a = self.withChildren(_.remove(childContext))
}
}
>>>
test does not parse
object a {
childContext.onDone(_ => def a = self.withChildren(_.remove(childContext)))
}
<<< #1756 type within lambda
object a {
childContext.onDone { _ =>
type a = Int
}
}
>>>
test does not parse
object a {
childContext.onDone(_ => type a = Int)
}
<<< #1756 val without lambda
object a {
childContext.onDone { val _ = self.withChildren(_.remove(childContext)) }
}
>>>
test does not parse
object a {
childContext.onDone(val _ = self.withChildren(_.remove(childContext)))
}
<<< #1756 def without lambda
object a {
childContext.onDone { def a = self.withChildren(_.remove(childContext)) }
}
>>>
test does not parse
object a {
childContext.onDone(def a = self.withChildren(_.remove(childContext)))
}
<<< #1756 type without lambda
object a {
childContext.onDone { type a = Int }
}
>>>
test does not parse
object a {
childContext.onDone(type a = Int)
}

0 comments on commit 2e574b4

Please sign in to comment.