@@ -9,19 +9,19 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
99 import tasty ._
1010 import syntaxHighlight ._
1111
12- def showTree (tree : Tree )( using ctx : Context ) : String =
12+ def showTree (tree : Tree ): String =
1313 (new Buffer ).printTree(tree).result()
1414
15- def showTypeOrBounds (tpe : TypeOrBounds )( using ctx : Context ) : String =
15+ def showTypeOrBounds (tpe : TypeOrBounds ): String =
1616 (new Buffer ).printTypeOrBound(tpe)(using None ).result()
1717
18- def showConstant (const : Constant )( using ctx : Context ) : String =
18+ def showConstant (const : Constant ): String =
1919 (new Buffer ).printConstant(const).result()
2020
21- def showSymbol (symbol : Symbol )( using ctx : Context ) : String =
21+ def showSymbol (symbol : Symbol ): String =
2222 symbol.fullName
2323
24- def showFlags (flags : Flags )( using ctx : Context ) : String = {
24+ def showFlags (flags : Flags ): String = {
2525 val flagList = List .newBuilder[String ]
2626 if (flags.is(Flags .Abstract )) flagList += " abstract"
2727 if (flags.is(Flags .Artifact )) flagList += " artifact"
@@ -60,7 +60,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
6060 flagList.result().mkString(" /*" , " " , " */" )
6161 }
6262
63- private class Buffer ( using ctx : Context ) {
63+ private class Buffer {
6464
6565 private [this ] val sb : StringBuilder = new StringBuilder
6666
@@ -1416,7 +1416,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14161416 private [this ] val names = collection.mutable.Map .empty[Symbol , String ]
14171417 private [this ] val namesIndex = collection.mutable.Map .empty[String , Int ]
14181418
1419- private def splicedName (sym : Symbol )( using ctx : Context ) : Option [String ] = {
1419+ private def splicedName (sym : Symbol ): Option [String ] = {
14201420 sym.annots.find(_.symbol.owner == Symbol .requiredClass(" scala.internal.quoted.showName" )).flatMap {
14211421 case Apply (_, Literal (Constant (c : String )) :: Nil ) => Some (c)
14221422 case Apply (_, Inlined (_, _, Literal (Constant (c : String ))) :: Nil ) => Some (c)
@@ -1437,7 +1437,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14371437 }
14381438
14391439 private object SpecialOp {
1440- def unapply (arg : Tree )( using ctx : Context ) : Option [(String , List [Term ])] = arg match {
1440+ def unapply (arg : Tree ): Option [(String , List [Term ])] = arg match {
14411441 case arg @ Apply (fn, args) =>
14421442 fn.tpe match {
14431443 case tpe @ TermRef (ThisType (TypeRef (_, name)), name2) if name == " <special-ops>" =>
@@ -1449,7 +1449,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14491449 }
14501450
14511451 private object Annotation {
1452- def unapply (arg : Tree )( using ctx : Context ) : Option [(TypeTree , List [Term ])] = arg match {
1452+ def unapply (arg : Tree ): Option [(TypeTree , List [Term ])] = arg match {
14531453 case New (annot) => Some ((annot, Nil ))
14541454 case Apply (Select (New (annot), " <init>" ), args) => Some ((annot, args))
14551455 case Apply (TypeApply (Select (New (annot), " <init>" ), targs), args) => Some ((annot, args))
@@ -1461,7 +1461,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14611461 private object Types {
14621462
14631463 object Sequence {
1464- def unapply (tpe : Type )( using ctx : Context ) : Option [Type ] = tpe match {
1464+ def unapply (tpe : Type ): Option [Type ] = tpe match {
14651465 case AppliedType (seq, (tp : Type ) :: Nil )
14661466 if seq.typeSymbol == Symbol .requiredClass(" scala.collection.Seq" ) || seq.typeSymbol == Symbol .requiredClass(" scala.collection.immutable.Seq" ) =>
14671467 Some (tp)
@@ -1470,7 +1470,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14701470 }
14711471
14721472 object Repeated {
1473- def unapply (tpe : Type )( using ctx : Context ) : Option [Type ] = tpe match {
1473+ def unapply (tpe : Type ): Option [Type ] = tpe match {
14741474 case AppliedType (rep, (tp : Type ) :: Nil ) if rep.typeSymbol == Symbol .requiredClass(" scala.<repeated>" ) => Some (tp)
14751475 case _ => None
14761476 }
@@ -1479,7 +1479,7 @@ class SourceCodePrinter[R <: Reflection & Singleton](val tasty: R)(syntaxHighlig
14791479 }
14801480
14811481 object PackageObject {
1482- def unapply (tree : Tree )( using ctx : Context ) : Option [Tree ] = tree match {
1482+ def unapply (tree : Tree ): Option [Tree ] = tree match {
14831483 case PackageClause (_, ValDef (" package" , _, _) :: body :: Nil ) => Some (body)
14841484 case _ => None
14851485 }
0 commit comments