Skip to content

Commit e9330e3

Browse files
authored
Merge pull request #846 from scalacenter/update/scalafmt-core-3.9.0
Update scalafmt-core to 3.9.0
2 parents 3752ae3 + f75470e commit e9330e3

10 files changed

+49
-46
lines changed

.git-blame-ignore-revs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
# Scala Steward: Reformat with scalafmt 3.8.4
22
7fd0641d92a10f1cc0d027860aa8c07caada0cdc
3+
4+
# Scala Steward: Reformat with scalafmt 3.9.0
5+
f597745711467c5e0f4e382086a5bbb7badd1354

.scalafmt.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version = "3.8.6"
1+
version = "3.9.0"
22
project.git = true
33
align.preset = none
44
align.stripMargin = true

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/ScalaEvaluationTests.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1952,7 +1952,7 @@ abstract class ScalaEvaluationTests(scalaVersion: ScalaVersion) extends DebugTes
19521952
|
19531953
|object Rewrites {
19541954
| private class Patch(var span: Span)
1955-
|
1955+
|
19561956
| def main(args: Array[String]): Unit = {
19571957
| val patch = new Patch(new Span(0))
19581958
| println("ok")
@@ -1987,7 +1987,7 @@ abstract class ScalaEvaluationTests(scalaVersion: ScalaVersion) extends DebugTes
19871987
|
19881988
|object Main {
19891989
| private class B extends A
1990-
|
1990+
|
19911991
| def main(args: Array[String]): Unit = {
19921992
| val b = new B
19931993
| println("foo")

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/ScalaStackTraceTests.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ class ScalaStackTraceTests extends DebugTestSuite {
7979
|}
8080
|
8181
|def m2(t : Int ) : Int = {
82-
| t*2
82+
| t*2
8383
|}
8484
|
8585
|object Main {
@@ -136,13 +136,13 @@ class ScalaStackTraceTests extends DebugTestSuite {
136136
val source =
137137
"""|package example
138138
|object Main :
139-
| def main(args: Array[String]): Unit =
139+
| def main(args: Array[String]): Unit =
140140
| class B :
141141
| def m() = {
142142
| println("hello")
143143
| }
144144
|
145-
| class C extends B
145+
| class C extends B
146146
| C().m()
147147
|""".stripMargin
148148
implicit val debuggee: TestingDebuggee = TestingDebuggee.mainClass(source, "example.Main", scalaVersion)

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/SourceBreakpointTests.scala

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ class Scala213SourceBreakpointTests extends SourceBreakpointTests(ScalaVersion.`
88
"""|package example
99
|object Main {
1010
| def main(args: Array[String]): Unit = {
11-
| List(new java.lang.Integer(1), new java.lang.Integer(2), new java.lang.Integer(3)).map { i =>
11+
| List(new java.lang.Integer(1), new java.lang.Integer(2), new java.lang.Integer(3)).map { i =>
1212
| val msg = i + 2
1313
| println(msg)
1414
| }
@@ -31,7 +31,7 @@ class Scala31PlusSourceBreakpointTests extends SourceBreakpointTests(ScalaVersio
3131
"""|package example
3232
|object Main {
3333
| def main(args: Array[String]): Unit = {
34-
| List(new java.lang.Integer(1), new java.lang.Integer(2), new java.lang.Integer(3)).map { i =>
34+
| List(new java.lang.Integer(1), new java.lang.Integer(2), new java.lang.Integer(3)).map { i =>
3535
| val msg = i + 2
3636
| println(msg)
3737
| println(s"$msg bis")
@@ -69,7 +69,7 @@ abstract class SourceBreakpointTests(val scalaVersion: ScalaVersion) extends Deb
6969
"""|package example
7070
|object Main {
7171
| def main(args: Array[String]): Unit = {
72-
| List(1, 2, 3).map { i =>
72+
| List(1, 2, 3).map { i =>
7373
| val msg = i.toString
7474
| println(msg)
7575
| }
@@ -86,7 +86,7 @@ abstract class SourceBreakpointTests(val scalaVersion: ScalaVersion) extends Deb
8686
"""|package example
8787
|object Main {
8888
| def main(args: Array[String]): Unit = {
89-
| val list = List(1, 2, 3).map { i =>
89+
| val list = List(1, 2, 3).map { i =>
9090
| val msg = i.toString
9191
| msg
9292
| }
@@ -115,7 +115,7 @@ abstract class SourceBreakpointTests(val scalaVersion: ScalaVersion) extends Deb
115115
|object Main {
116116
| def main(args: Array[String]): Unit = {
117117
| val i: Int = 3
118-
|
118+
|
119119
| print(i)
120120
| ()
121121
|

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/StepFilterTests.scala

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
1818
| def m1(xs: String*) = println(xs.mkString)
1919
| def m2(xs: Int*) = println(xs.mkString)
2020
| def m3(xs: Unit*) = println(xs.mkString)
21-
|
21+
|
2222
| def main(args: Array[String]): Unit = {
2323
| m1("a", "b")
2424
| m2(1, 2)
@@ -313,11 +313,11 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
313313
|object Main {
314314
| var x1 = "x1"
315315
| private var x2 = "x2"
316-
|
316+
|
317317
| def main(args: Array[String]): Unit = {
318318
| x1 = "x1"
319319
| x2 = "x2"
320-
|
320+
|
321321
| val c = new C("c1", "c2")
322322
| c.m()
323323
| }
@@ -335,7 +335,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
335335
|class C(var c1: String, private var c2: String) extends B with A {
336336
| /* override */ var a1: String = "a1"
337337
| private var c3: String = "c3"
338-
|
338+
|
339339
| def m(): Unit = {
340340
| a1 = "a1"
341341
| b1 = "b1"
@@ -509,7 +509,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
509509
| def main(args: Array[String]): Unit = {
510510
| val a = new A("a")
511511
| val b = new A("b")
512-
|
512+
|
513513
| a.toString
514514
| a.copy("b")
515515
| a.hashCode()
@@ -518,7 +518,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
518518
| a.productPrefix
519519
| a.productElement(0)
520520
| a.productIterator
521-
|
521+
|
522522
| val f = A
523523
| f("a")
524524
|
@@ -733,7 +733,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
733733
|
734734
|object Main {
735735
| def m(x: "a"): 1 = 1
736-
|
736+
|
737737
| def main(args: Array[String]): Unit = {
738738
| m("a")
739739
| }
@@ -755,7 +755,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
755755
| type Foo = A
756756
| type Bar = String
757757
| def m(x: Foo): Bar = x.toString
758-
|
758+
|
759759
| def main(args: Array[String]): Unit = {
760760
| val foo = new A
761761
| m(foo)
@@ -777,11 +777,11 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
777777
| def m1(): A with B { def foo: String } = {
778778
| new A with B { def foo: String = toString }
779779
| }
780-
|
780+
|
781781
| def m2(): { def foo: String } = {
782782
| new { def foo: String = toString }
783783
| }
784-
|
784+
|
785785
| def main(args: Array[String]): Unit = {
786786
| m1()
787787
| m2()
@@ -800,9 +800,9 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
800800
|
801801
|trait B {
802802
| type X <: A
803-
|
803+
|
804804
| def m1(x: X): X = x
805-
| def m2[T <: X](x: T) = x
805+
| def m2[T <: X](x: T) = x
806806
|}
807807
|
808808
|class C extends B {
@@ -1051,7 +1051,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
10511051
| x.m
10521052
| &(x)
10531053
| }
1054-
|
1054+
|
10551055
| def &(x: <>): String = x.toString
10561056
|}
10571057
|
@@ -1079,7 +1079,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
10791079
| def main(xs: Array[String]): Unit = {
10801080
| fac(2)
10811081
| }
1082-
|
1082+
|
10831083
| def fac(x: Int): Int = {
10841084
| def rec(x: Int, acc: Int): Int = {
10851085
| if (x <= 0) acc
@@ -1259,7 +1259,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
12591259
| def m1(xs: String*) = println(xs.mkString)
12601260
| def m2(xs: Int*) = println(xs.mkString)
12611261
| def m3(xs: Unit*) = println(xs.mkString)
1262-
|
1262+
|
12631263
| def main(args: Array[String]): Unit = {
12641264
| m1("a", "b")
12651265
| m2(1, 2)
@@ -1324,7 +1324,7 @@ abstract class StepFilterTests(protected val scalaVersion: ScalaVersion) extends
13241324
|case class B(a: A):
13251325
| export a.*
13261326
|
1327-
|@main def Main =
1327+
|@main def Main =
13281328
| val b = B(A())
13291329
| b.aa
13301330
|""".stripMargin

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/internal/JavaRuntimeEvaluatorTests.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,14 @@ class JavaRuntimeEvaluatorTests extends DebugTestSuite {
5252
| public Foo() {
5353
| this.friendFoo = new FriendFoo(this);
5454
| }
55-
|
55+
|
5656
| public FriendFoo friendFoo(Foo f) { return new FriendFoo(f); }
5757
| class FriendFoo {
5858
| public Foo f;
5959
| public int y = 42;
6060
| public static final int z = 43;
6161
| public static final String greet = "Friendly";
62-
|
62+
|
6363
| public FriendFoo(Foo f) { this.f = f; }
6464
| public String greet() { return "Friend"; }
6565
| public int add(int x, int y) { return x + y; }
@@ -121,7 +121,7 @@ class JavaRuntimeEvaluatorTests extends DebugTestSuite {
121121
| }
122122
|}
123123
|
124-
|class SuperFoo {
124+
|class SuperFoo {
125125
| private String superfoo = "hello super";
126126
| public static String foofoo = "superfoofoo";
127127
|}
@@ -175,7 +175,7 @@ class JavaRuntimeEvaluatorTests extends DebugTestSuite {
175175
| public static String staticMethod() { return "i am static"; }
176176
|}
177177
|
178-
|class SuperFoo {
178+
|class SuperFoo {
179179
| public static String staticMethod() { return "i am static superfoo"; }
180180
|}
181181
|

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/internal/MetalsClassBreakpointSuite.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ class MetalsClassBreakpointSuite extends FunSuite {
130130
check(
131131
"""|package a
132132
|
133-
|@main
133+
|@main
134134
|def helloWorld(): Unit = {
135135
| object Even {
136136
|>> def unapply(s: String): Boolean = s.size % 2 == 0
@@ -146,13 +146,13 @@ class MetalsClassBreakpointSuite extends FunSuite {
146146
check(
147147
"""|package a
148148
|
149-
|@main
150-
|def hello(): Unit =
149+
|@main
150+
|def hello(): Unit =
151151
| greet("Alice")
152152
| greet("Bob")
153153
| System.exit(0)
154154
|
155-
|def greet(name: String) =
155+
|def greet(name: String) =
156156
| val message = s"Hello, $name!"
157157
|>>println(message)
158158
|

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/internal/RuntimeEvaluatorTests.scala

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ object RuntimeEvaluatorEnvironments {
4141
|
4242
|trait FooTrait { val foo1: String = "hello there" }
4343
|
44-
|class SuperFoo {
44+
|class SuperFoo {
4545
| private val superfoo: String = "hello super"
4646
| def keepSuperfoo: String = superfoo
4747
|}
@@ -80,8 +80,8 @@ object RuntimeEvaluatorEnvironments {
8080
| object InnerFoo { def hello: String = "hello main inner foo" }
8181
|}
8282
|
83-
|trait FooTrait {
84-
| val x = 3
83+
|trait FooTrait {
84+
| val x = 3
8585
| def bar1: Int = 42
8686
|}
8787
|
@@ -130,7 +130,7 @@ object RuntimeEvaluatorEnvironments {
130130
| val subCool = new SubCool()
131131
| println("ok")
132132
| }
133-
|
133+
|
134134
| def test(foo: Foo): String = "foo"
135135
| def test(bar: Bar): String = "bar"
136136
| def test(baz: Baz): String = "baz"
@@ -171,11 +171,11 @@ object RuntimeEvaluatorEnvironments {
171171
| case class Inner(x: Int) {
172172
| val y = x + 1
173173
| def helloInner = s"hello inner $x"
174-
| case class InnerInner() {
174+
| case class InnerInner() {
175175
| val str = {
176176
| println("ok")
177177
| s"inner inner $y"
178-
| }
178+
| }
179179
| }
180180
| object InnerInner {
181181
| val str = {
@@ -184,7 +184,7 @@ object RuntimeEvaluatorEnvironments {
184184
| }
185185
| }
186186
| }
187-
| object Inner {
187+
| object Inner {
188188
| val z = 42
189189
| def helloInner = "hello inner"
190190
| case class DoubleInner(zz: Int) { val str = s"double inner $zz"}
@@ -237,7 +237,7 @@ object RuntimeEvaluatorEnvironments {
237237
| def main(args: Array[String]): Unit = {
238238
| println("ok")
239239
| }
240-
|
240+
|
241241
| def test(i: Int): String = "primitive int"
242242
| def test(i: java.lang.Integer): String = "boxed int"
243243
|}
@@ -254,7 +254,7 @@ object RuntimeEvaluatorEnvironments {
254254
| val seq = Seq(1, 2, 3)
255255
| val vector = Vector(1, 2, 3)
256256
| println("ok")
257-
| }
257+
| }
258258
|}
259259
|""".stripMargin
260260

@@ -1038,7 +1038,7 @@ abstract class ScalaRuntimeEvaluatorTests(val scalaVersion: ScalaVersion) extend
10381038
|
10391039
|object Main {
10401040
| var b = 0
1041-
| var c = 0
1041+
| var c = 0
10421042
| def main(args: Array[String]): Unit = {
10431043
| val a = new A
10441044
| var b = 0

modules/tests/src/test/scala/ch/epfl/scala/debugadapter/internal/RuntimePreEvaluationTests.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ abstract class RuntimePreEvaluationTests(val scalaVersion: ScalaVersion) extends
8383
| case object Baz extends InnerFoo {
8484
| val baz: Int = 2
8585
| }
86-
|
86+
|
8787
| val innerBar: InnerFoo = Bar
8888
| val innerBaz: InnerFoo = Baz
8989
|}

0 commit comments

Comments
 (0)