Skip to content

Commit

Permalink
internal: Upgrade to scalafmt 3.8.2 and use explicit Scala 2/3 dialec…
Browse files Browse the repository at this point in the history
…t specification (#3565)
  • Loading branch information
xerial authored Jun 18, 2024
1 parent fba23ef commit e61b057
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
14 changes: 10 additions & 4 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version = 3.8.1
version = 3.8.2
project.layout = StandardConvention
runner.dialect = scala3
maxColumn = 120
Expand All @@ -20,11 +20,17 @@ runner.dialectOverride.allowSignificantIndentation = false
runner.dialectOverride.allowQuestionMarkAsTypeWildcard = false

fileOverride {
"glob:**/scala/**" {
runner.dialect = scala213source3
}
"glob:**/scala-2/**" {
runner.dialect = scala213source3
runner.dialect = scala213source3
}
"glob:**/scala-3/**" {
runner.dialect = scala3
}
"glob:**/scala-3/wvlet/log/LoggerBase.scala" {
// optional brace didn't work for code with inline/macro methods
rewrite.scala3.removeOptionalBraces = no
// optional brace didn't work for code with inline/macro methods
rewrite.scala3.removeOptionalBraces = no
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ object HealthCheckPolicy extends LogSupport {

private def setAndMove(v: Boolean): Unit = {
val i = (executionCount % numExecutions).toInt
val mask = 1L << (63 - i % 64)
val mask = 1L << (63 - i % 64)
if (v == true) {
executionHistory(i / 64) |= mask
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ class HtmlTest extends AirSpec {
style.noValue
)

val d = div()
val d = div()
d(style -> "width: 10px;")
d.addModifier(cls -> "test")
}
Expand Down

0 comments on commit e61b057

Please sign in to comment.