Skip to content

Commit 65fb732

Browse files
committed
replace "quick fix available" with "quickfixable"
1 parent 28c2e67 commit 65fb732

File tree

92 files changed

+293
-293
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+293
-293
lines changed

src/compiler/scala/tools/nsc/Reporting.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ trait Reporting extends internal.Reporting { self: ast.Positions with Compilatio
169169

170170
val quickfixed = {
171171
if (!skipRewriteAction(action) && registerTextEdit(warning)) s"[rewritten by -quickfix] ${warning.msg}"
172-
else if (warning.actions.exists(_.edits.nonEmpty) && !settings.quickFixSilent) s"${warning.msg} [quick fix available]"
172+
else if (warning.actions.exists(_.edits.nonEmpty) && !settings.quickFixSilent) s"${warning.msg} [quickfixable]"
173173
else warning.msg
174174
}
175175

@@ -361,7 +361,7 @@ trait Reporting extends internal.Reporting { self: ast.Positions with Compilatio
361361
def error(pos: Position, msg: String, actions: List[CodeAction]): Unit = {
362362
val quickfixed = {
363363
if (registerErrorTextEdit(pos, msg, actions)) s"[rewritten by -quickfix] $msg"
364-
else if (actions.exists(_.edits.nonEmpty) && !settings.quickFixSilent) s"$msg [quick fix available]"
364+
else if (actions.exists(_.edits.nonEmpty) && !settings.quickFixSilent) s"$msg [quickfixable]"
365365
else msg
366366
}
367367
reporter.error(pos, quickfixed, actions)

src/compiler/scala/tools/nsc/settings/StandardScalaSettings.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ trait StandardScalaSettings { _: MutableSettings =>
6565
|
6666
|Use `-Wconf:any:warning-verbose` to display applicable message filters with each warning.
6767
|
68-
|Use `-quickfix:silent` to omit the `[quick fix available]` tag in compiler messages.
68+
|Use `-quickfix:silent` to omit the `[quickfixable]` tag in compiler messages.
6969
|""".stripMargin),
7070
prepend = true)
7171
def quickFixSilent: Boolean = quickfix.value == List("silent")

test/files/jvm/interpreter.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ class Bar
8888

8989
scala> implicit def foo2bar(foo: Foo) = Bar(foo.n)
9090
^
91-
warning: Implicit definition should have explicit type (inferred Bar) [quick fix available]
91+
warning: Implicit definition should have explicit type (inferred Bar) [quickfixable]
9292
warning: 1 feature warning; for details, enable `:setting -feature` or `:replay -feature`
9393
def foo2bar(foo: Foo): Bar
9494

test/files/neg/auto-application.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ auto-application.scala:6: error: Int does not take parameters
99
^
1010
auto-application.scala:9: warning: Auto-application to `()` is deprecated. Supply the empty argument list `()` explicitly to invoke method meth,
1111
or remove the empty argument list from its definition (Java-defined methods are exempt).
12-
In Scala 3, an unapplied method like this will be eta-expanded into a function. [quick fix available]
12+
In Scala 3, an unapplied method like this will be eta-expanded into a function. [quickfixable]
1313
meth // warn, auto-application (of nilary methods) is deprecated
1414
^
1515
1 warning

test/files/neg/checksensible.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
checksensible.scala:54: warning: symbol literal is deprecated; use Symbol("sym") instead [quick fix available]
1+
checksensible.scala:54: warning: symbol literal is deprecated; use Symbol("sym") instead [quickfixable]
22
(1 != 'sym)
33
^
44
checksensible.scala:15: warning: comparing a fresh object using `eq` will always yield false

test/files/neg/deprecated_widening.check

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,55 @@
1-
deprecated_widening.scala:5: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
1+
deprecated_widening.scala:5: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
22
val i_f: Float = i // deprecated
33
^
4-
deprecated_widening.scala:7: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
4+
deprecated_widening.scala:7: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
55
val l_f: Float = l // deprecated
66
^
7-
deprecated_widening.scala:8: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quick fix available]
7+
deprecated_widening.scala:8: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quickfixable]
88
val l_d: Double = l // deprecated
99
^
10-
deprecated_widening.scala:23: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
10+
deprecated_widening.scala:23: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
1111
val truncatedPosFloat:Float = 16777217L // deprecated
1212
^
13-
deprecated_widening.scala:26: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
13+
deprecated_widening.scala:26: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
1414
val truncatedNegFloat: Float = - 16777217L // deprecated
1515
^
16-
deprecated_widening.scala:30: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
16+
deprecated_widening.scala:30: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
1717
val truncatedPosFloatI:Float = 16777217 // deprecated
1818
^
19-
deprecated_widening.scala:33: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
19+
deprecated_widening.scala:33: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
2020
val truncatedNegFloatI: Float = - 16777217 // deprecated
2121
^
22-
deprecated_widening.scala:37: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quick fix available]
22+
deprecated_widening.scala:37: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quickfixable]
2323
val truncatedPosDouble:Double = 18014398509481985L // deprecated
2424
^
25-
deprecated_widening.scala:40: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quick fix available]
25+
deprecated_widening.scala:40: warning: Widening conversion from Long to Double is deprecated because it loses precision. Write `.toDouble` instead. [quickfixable]
2626
val truncatedNegDouble: Double = - 18014398509481985L // deprecated
2727
^
28-
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
28+
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
2929
def literals = Set[Float](0x7fffffc0, 0x7ffffffd, 0x7ffffffe, 0x7fffffff)
3030
^
31-
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
31+
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
3232
def literals = Set[Float](0x7fffffc0, 0x7ffffffd, 0x7ffffffe, 0x7fffffff)
3333
^
34-
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
34+
deprecated_widening.scala:47: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
3535
def literals = Set[Float](0x7fffffc0, 0x7ffffffd, 0x7ffffffe, 0x7fffffff)
3636
^
37-
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
37+
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
3838
def longingly = Set[Float](0x7fffffc0L, 0x7ffffffdL, 0x7ffffffeL, 0x7fffffffL)
3939
^
40-
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
40+
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
4141
def longingly = Set[Float](0x7fffffc0L, 0x7ffffffdL, 0x7ffffffeL, 0x7fffffffL)
4242
^
43-
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
43+
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
4444
def longingly = Set[Float](0x7fffffc0L, 0x7ffffffdL, 0x7ffffffeL, 0x7fffffffL)
4545
^
46-
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
46+
deprecated_widening.scala:48: warning: Widening conversion from Long to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
4747
def longingly = Set[Float](0x7fffffc0L, 0x7ffffffdL, 0x7ffffffeL, 0x7fffffffL)
4848
^
49-
deprecated_widening.scala:50: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
49+
deprecated_widening.scala:50: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
5050
def `pick one` = Set[Float](0x1000003, 0x1000004, 0x1000005)
5151
^
52-
deprecated_widening.scala:50: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quick fix available]
52+
deprecated_widening.scala:50: warning: Widening conversion from Int to Float is deprecated because it loses precision. Write `.toFloat` instead. [quickfixable]
5353
def `pick one` = Set[Float](0x1000003, 0x1000004, 0x1000005)
5454
^
5555
deprecated_widening.scala:12: warning: method int2float in object Int is deprecated (since 2.13.1): Implicit conversion from Int to Float is dangerous because it loses precision. Write `.toFloat` instead.

test/files/neg/dotless-targs-a.check

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
dotless-targs-a.scala:4: error: type application is not allowed for infix operators [quick fix available]
1+
dotless-targs-a.scala:4: error: type application is not allowed for infix operators [quickfixable]
22
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
33
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
44
def fn2 = List apply[Int] 2
55
^
6-
dotless-targs-a.scala:9: error: type application is not allowed for infix operators [quick fix available]
6+
dotless-targs-a.scala:9: error: type application is not allowed for infix operators [quickfixable]
77
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
88
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
99
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)
1010
^
11-
dotless-targs-a.scala:9: error: type application is not allowed for infix operators [quick fix available]
11+
dotless-targs-a.scala:9: error: type application is not allowed for infix operators [quickfixable]
1212
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
1313
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
1414
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)

test/files/neg/dotless-targs-b.check

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
dotless-targs-b.scala:4: error: type application is not allowed for infix operators [quick fix available]
1+
dotless-targs-b.scala:4: error: type application is not allowed for infix operators [quickfixable]
22
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
33
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
44
def fn2 = List apply[Int] 2
55
^
6-
dotless-targs-b.scala:9: error: type application is not allowed for infix operators [quick fix available]
6+
dotless-targs-b.scala:9: error: type application is not allowed for infix operators [quickfixable]
77
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
88
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
99
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)
1010
^
11-
dotless-targs-b.scala:9: error: type application is not allowed for infix operators [quick fix available]
11+
dotless-targs-b.scala:9: error: type application is not allowed for infix operators [quickfixable]
1212
Scala 3 migration messages are errors under -Xsource:3. Use -Wconf / @nowarn to filter them or add -Xmigration to demote them to warnings.
1313
Applicable -Wconf / @nowarn filters for this fatal warning: msg=<part of the message>, cat=scala3-migration
1414
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)

test/files/neg/dotless-targs-ranged-a.check

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
dotless-targs-ranged-a.scala:4: warning: type application is not allowed for infix operators [quick fix available]
1+
dotless-targs-ranged-a.scala:4: warning: type application is not allowed for infix operators [quickfixable]
22
def fn2 = List apply[Int] 2
33
^
4-
dotless-targs-ranged-a.scala:9: warning: type application is not allowed for infix operators [quick fix available]
4+
dotless-targs-ranged-a.scala:9: warning: type application is not allowed for infix operators [quickfixable]
55
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)
66
^
7-
dotless-targs-ranged-a.scala:9: warning: type application is not allowed for infix operators [quick fix available]
7+
dotless-targs-ranged-a.scala:9: warning: type application is not allowed for infix operators [quickfixable]
88
def h1 = List apply[List[Int]] (List(1), List(2)) mapConserve[List[Any]] (x => x)
99
^
10-
dotless-targs-ranged-a.scala:13: warning: type application is not allowed for infix operators [quick fix available]
10+
dotless-targs-ranged-a.scala:13: warning: type application is not allowed for infix operators [quickfixable]
1111
def eval = 1 ->[Int] 2
1212
^
13-
dotless-targs-ranged-a.scala:14: warning: type application is not allowed for infix operators [quick fix available]
13+
dotless-targs-ranged-a.scala:14: warning: type application is not allowed for infix operators [quickfixable]
1414
def evil = new A() op [Int, String ] 42
1515
^
1616
dotless-targs-ranged-a.scala:9: warning: multiarg infix syntax looks like a tuple and will be deprecated

test/files/neg/for-comprehension-old.check

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
for-comprehension-old.scala:6: error: `val` keyword in for comprehension is unsupported: just remove `val` [quick fix available]
1+
for-comprehension-old.scala:6: error: `val` keyword in for comprehension is unsupported: just remove `val` [quickfixable]
22
for (val x <- 1 to 5 ; y = x) yield x+y // fail
33
^
4-
for-comprehension-old.scala:7: error: `val` keyword in for comprehension is unsupported: just remove `val` [quick fix available]
4+
for-comprehension-old.scala:7: error: `val` keyword in for comprehension is unsupported: just remove `val` [quickfixable]
55
for (val x <- 1 to 5 ; val y = x) yield x+y // fail
66
^
7-
for-comprehension-old.scala:11: error: `val` keyword in for comprehension is unsupported: just remove `val` [quick fix available]
7+
for-comprehension-old.scala:11: error: `val` keyword in for comprehension is unsupported: just remove `val` [quickfixable]
88
for (z <- 1 to 2 ; val x <- 1 to 5 ; y = x) yield x+y // fail
99
^
10-
for-comprehension-old.scala:12: error: `val` keyword in for comprehension is unsupported: just remove `val` [quick fix available]
10+
for-comprehension-old.scala:12: error: `val` keyword in for comprehension is unsupported: just remove `val` [quickfixable]
1111
for (z <- 1 to 2 ; val x <- 1 to 5 ; val y = x) yield x+y // fail
1212
^
13-
for-comprehension-old.scala:5: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quick fix available]
13+
for-comprehension-old.scala:5: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quickfixable]
1414
for (x <- 1 to 5 ; val y = x) yield x+y // fail
1515
^
16-
for-comprehension-old.scala:7: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quick fix available]
16+
for-comprehension-old.scala:7: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quickfixable]
1717
for (val x <- 1 to 5 ; val y = x) yield x+y // fail
1818
^
19-
for-comprehension-old.scala:10: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quick fix available]
19+
for-comprehension-old.scala:10: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quickfixable]
2020
for (z <- 1 to 2 ; x <- 1 to 5 ; val y = x) yield x+y // fail
2121
^
22-
for-comprehension-old.scala:12: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quick fix available]
22+
for-comprehension-old.scala:12: warning: `val` keyword in for comprehension is deprecated: instead, bind the value without `val` [quickfixable]
2323
for (z <- 1 to 2 ; val x <- 1 to 5 ; val y = x) yield x+y // fail
2424
^
2525
4 warnings

0 commit comments

Comments
 (0)