-
Notifications
You must be signed in to change notification settings - Fork 186
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Injecting instances of pprint.TPrint to customize the docs no longer has effect as of ffcd8b9, which was a silent breaking change. This commit exposes the breaking change so that rules built against the latest scalafix-core either drop usage of TPrint or switch to the shaded version which is used internally by metaconfig.
- Loading branch information
Showing
9 changed files
with
47 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
scalafix-rules/src/main/scala-2.11/scalafix/internal/rule/TPrintImplicits.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package scalafix.internal.rule | ||
|
||
import java.util.regex.Pattern | ||
|
||
import pprint.TPrint | ||
import scalafix.config.CustomMessage | ||
|
||
class TPrintImplicits { | ||
implicit val tprintPattern: TPrint[List[CustomMessage[Pattern]]] = | ||
TPrint.literal("List[Regex]") | ||
} |
13 changes: 13 additions & 0 deletions
13
scalafix-rules/src/main/scala-2.12+/scalafix/internal/rule/TPrintImplicits.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package scalafix.internal.rule | ||
|
||
import java.util.regex.Pattern | ||
|
||
import metaconfig.pprint._ | ||
import scalafix.config.CustomMessage | ||
|
||
class TPrintImplicits { | ||
implicit val tprintPattern: TPrint[List[CustomMessage[Pattern]]] = | ||
new TPrint[List[CustomMessage[Pattern]]] { | ||
def render(implicit tpc: TPrintColors): fansi.Str = fansi.Str("List[Regex]") | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters