@@ -115,6 +115,10 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
115115         |    a + b 
116116         |}"""  .stripMargin,
117117      List [String ](
118+         """ |object Main extends App {
119+            |  def func(>>region>>a<<region<<: Int, b: Int) = 
120+            |    a + b 
121+            |}"""  .stripMargin,
118122        """ |object Main extends App {
119123           |  def func(>>region>>a: Int<<region<<, b: Int) = 
120124           |    a + b 
@@ -137,6 +141,10 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
137141         |    a + b 
138142         |}"""  .stripMargin,
139143      List [String ](
144+         """ |object Main extends App {
145+            |  val func = (>>region>>a<<region<<: Int, b: Int) => 
146+            |    a + b 
147+            |}"""  .stripMargin,
140148        """ |object Main extends App {
141149           |  val func = (>>region>>a: Int<<region<<, b: Int) => 
142150           |    a + b 
@@ -160,6 +168,7 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
160168    check(
161169      " object Main extends App { def foo[Type@@ <: T1, B](hi: Int, b: Int, c:Int) = ??? }" 
162170      List (
171+         " object Main extends App { def foo[>>region>>Type<<region<< <: T1, B](hi: Int, b: Int, c:Int) = ??? }" 
163172        " object Main extends App { def foo[>>region>>Type <: T1<<region<<, B](hi: Int, b: Int, c:Int) = ??? }" 
164173        " object Main extends App { def foo[>>region>>Type <: T1, B<<region<<](hi: Int, b: Int, c:Int) = ??? }" 
165174        " object Main extends App { >>region>>def foo[Type <: T1, B](hi: Int, b: Int, c:Int) = ???<<region<< }" 
@@ -192,6 +201,7 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
192201    check(
193202      " val hello = (aaa: Int, bb@@b: Int, ccc: Int) => ???" 
194203      List (
204+         " val hello = (aaa: Int, >>region>>bbb<<region<<: Int, ccc: Int) => ???" 
195205        " val hello = (aaa: Int, >>region>>bbb: Int<<region<<, ccc: Int) => ???" 
196206        " val hello = (>>region>>aaa: Int, bbb: Int, ccc: Int<<region<<) => ???" 
197207        " val hello = >>region>>(aaa: Int, bbb: Int, ccc: Int) => ???<<region<<" 
@@ -203,6 +213,7 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
203213    check(
204214      " def hello(aaa: Int, bb@@b: Int, ccc: Int) = ???" 
205215      List (
216+         " def hello(aaa: Int, >>region>>bbb<<region<<: Int, ccc: Int) = ???" 
206217        " def hello(aaa: Int, >>region>>bbb: Int<<region<<, ccc: Int) = ???" 
207218        " def hello(>>region>>aaa: Int, bbb: Int, ccc: Int<<region<<) = ???" 
208219        " >>region>>def hello(aaa: Int, bbb: Int, ccc: Int) = ???<<region<<" 
@@ -252,3 +263,21 @@ class SelectionRangeSuite extends BaseSelectionRangeSuite:
252263        " >>region>>def hello = List(222)<<region<<" 
253264      )
254265    )
266+ 
267+   @ Test  def  `constructor-argument`  = 
268+     check(
269+       " class Foo(val ar@@g: Int)" 
270+       List (
271+         """ class Foo(val >>region>>arg<<region<<: Int)""" 
272+         """ class Foo(>>region>>val arg: Int<<region<<)""" 
273+       )
274+     )
275+ 
276+   @ Test  def  `object-backticked`  = 
277+     check(
278+       " object `Foo B@@ar Baz` extends SomeTrait" 
279+       List (
280+         """ object `>>region>>Foo Bar Baz<<region<<` extends SomeTrait""" 
281+         """ >>region>>object `Foo Bar Baz` extends SomeTrait<<region<<""" 
282+       )
283+     )
0 commit comments