@@ -14,7 +14,7 @@ import dotty.tools.dotc.quoted.QuoteUtils._
14
14
import dotty .tools .dotc .core .Decorators ._
15
15
16
16
import scala .quoted .QuoteContext
17
- import scala .quoted .reflect .printers .{ExtractorsPrinter , SourceCodePrinter , SyntaxHighlight }
17
+ import scala .quoted .reflect .printers .{Extractors , SourceCode , SyntaxHighlight }
18
18
19
19
import scala .internal .quoted .PickledQuote
20
20
import scala .tasty .reflect ._
@@ -65,11 +65,11 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext:
65
65
def pos : Position = self.sourcePos
66
66
def symbol : Symbol = self.symbol
67
67
def showExtractors : String =
68
- new ExtractorsPrinter () .showTree(using QuoteContextImpl .this )(self)
68
+ Extractors .showTree(using QuoteContextImpl .this )(self)
69
69
def show : String =
70
70
self.showWith(SyntaxHighlight .plain)
71
71
def showWith (syntaxHighlight : SyntaxHighlight ): String =
72
- new SourceCodePrinter (syntaxHighlight) .showTree(using QuoteContextImpl .this )(self)
72
+ SourceCode .showTree(using QuoteContextImpl .this )(self)(syntaxHighlight )
73
73
def isExpr : Boolean =
74
74
self match
75
75
case TermTypeTest (self) =>
@@ -1589,13 +1589,13 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext:
1589
1589
object TypeMethodsImpl extends TypeMethods :
1590
1590
extension (self : TypeRepr ):
1591
1591
def showExtractors : String =
1592
- new ExtractorsPrinter () .showType(using QuoteContextImpl .this )(self)
1592
+ Extractors .showType(using QuoteContextImpl .this )(self)
1593
1593
1594
1594
def show : String =
1595
1595
self.showWith(SyntaxHighlight .plain)
1596
1596
1597
1597
def showWith (syntaxHighlight : SyntaxHighlight ): String =
1598
- new SourceCodePrinter (syntaxHighlight) .showType(using QuoteContextImpl .this )(self)
1598
+ SourceCode .showType(using QuoteContextImpl .this )(self)(syntaxHighlight )
1599
1599
1600
1600
def seal : scala.quoted.Type [_] =
1601
1601
new scala.internal.quoted.Type (Inferred (self), QuoteContextImpl .this .hashCode)
@@ -2172,11 +2172,11 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext:
2172
2172
extension (self : Constant ):
2173
2173
def value : Any = self.value
2174
2174
def showExtractors : String =
2175
- new ExtractorsPrinter () .showConstant(using QuoteContextImpl .this )(self)
2175
+ Extractors .showConstant(using QuoteContextImpl .this )(self)
2176
2176
def show : String =
2177
2177
self.showWith(SyntaxHighlight .plain)
2178
2178
def showWith (syntaxHighlight : SyntaxHighlight ): String =
2179
- new SourceCodePrinter (syntaxHighlight) .showConstant(using QuoteContextImpl .this )(self)
2179
+ SourceCode .showConstant(using QuoteContextImpl .this )(self)(syntaxHighlight )
2180
2180
end extension
2181
2181
end ConstantMethodsImpl
2182
2182
@@ -2395,11 +2395,11 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext:
2395
2395
def children : List [Symbol ] = self.denot.children
2396
2396
2397
2397
def showExtractors : String =
2398
- new ExtractorsPrinter () .showSymbol(using QuoteContextImpl .this )(self)
2398
+ Extractors .showSymbol(using QuoteContextImpl .this )(self)
2399
2399
def show : String =
2400
2400
self.showWith(SyntaxHighlight .plain)
2401
2401
def showWith (syntaxHighlight : SyntaxHighlight ): String =
2402
- new SourceCodePrinter (syntaxHighlight) .showSymbol(using QuoteContextImpl .this )(self)
2402
+ SourceCode .showSymbol(using QuoteContextImpl .this )(self)(syntaxHighlight )
2403
2403
2404
2404
end extension
2405
2405
@@ -2531,11 +2531,11 @@ class QuoteContextImpl private (ctx: Context) extends QuoteContext:
2531
2531
def | (that : Flags ): Flags = dotc.core.Flags .extension_|(self)(that)
2532
2532
def & (that : Flags ): Flags = dotc.core.Flags .extension_&(self)(that)
2533
2533
def showExtractors : String =
2534
- new ExtractorsPrinter () .showFlags(using QuoteContextImpl .this )(self)
2534
+ Extractors .showFlags(using QuoteContextImpl .this )(self)
2535
2535
def show : String =
2536
2536
self.showWith(SyntaxHighlight .plain)
2537
2537
def showWith (syntaxHighlight : SyntaxHighlight ): String =
2538
- new SourceCodePrinter (syntaxHighlight) .showFlags(using QuoteContextImpl .this )(self)
2538
+ SourceCode .showFlags(using QuoteContextImpl .this )(self)(syntaxHighlight )
2539
2539
end extension
2540
2540
end FlagsMethodsImpl
2541
2541
0 commit comments