@@ -61,7 +61,7 @@ object Expr {
6161 * ```
6262 */
6363 def betaReduce [F , Args <: Tuple , R , G ](f : Expr [F ])(using tf : TupledFunction [F , Args => R ], tg : TupledFunction [G , TupleOfExpr [Args ] => Expr [R ]], qctx : QuoteContext ): G = {
64- import qctx .tasty .{ _ , given _ }
64+ import qctx .tasty ._
6565 tg.untupled(args => qctx.tasty.internal.betaReduce(f.unseal, args.toArray.toList.map(_.asInstanceOf [QuoteContext => Expr [_]](qctx).unseal)).seal.asInstanceOf [Expr [R ]])
6666 }
6767
@@ -74,19 +74,19 @@ object Expr {
7474 * ```
7575 */
7676 def betaReduceGiven [F , Args <: Tuple , R , G ](f : Expr [F ])(using tf : TupledFunction [F , Args ?=> R ], tg : TupledFunction [G , TupleOfExpr [Args ] => Expr [R ]], qctx : QuoteContext ): G = {
77- import qctx .tasty .{ _ , given _ }
77+ import qctx .tasty ._
7878 tg.untupled(args => qctx.tasty.internal.betaReduce(f.unseal, args.toArray.toList.map(_.asInstanceOf [QuoteContext => Expr [_]](qctx).unseal)).seal.asInstanceOf [Expr [R ]])
7979 }
8080
8181 /** Returns a null expresssion equivalent to `'{null}` */
8282 def nullExpr : QuoteContext ?=> Expr [Null ] = qctx ?=> {
83- import qctx .tasty .{ _ , given _ }
83+ import qctx .tasty ._
8484 Literal (Constant (null )).seal.asInstanceOf [Expr [Null ]]
8585 }
8686
8787 /** Returns a unit expresssion equivalent to `'{}` or `'{()}` */
8888 def unitExpr : QuoteContext ?=> Expr [Unit ] = qctx ?=> {
89- import qctx .tasty .{ _ , given _ }
89+ import qctx .tasty ._
9090 Literal (Constant (())).seal.asInstanceOf [Expr [Unit ]]
9191 }
9292
@@ -95,7 +95,7 @@ object Expr {
9595 * will be equivalent to `'{ $s1; $s2; ...; $e }`.
9696 */
9797 def block [T ](statements : List [Expr [_]], expr : Expr [T ])(using qctx : QuoteContext ): Expr [T ] = {
98- import qctx .tasty .{ _ , given _ }
98+ import qctx .tasty ._
9999 Block (statements.map(_.unseal), expr.unseal).seal.asInstanceOf [Expr [T ]]
100100 }
101101
@@ -184,7 +184,7 @@ object Expr {
184184
185185 /** Given a tuple of the form `(Expr[A1], ..., Expr[An])`, outputs a tuple `Expr[(A1, ..., An)]`. */
186186 def ofTuple [T <: Tuple : Tuple .IsMappedBy [Expr ]: Type ](tup : T )(using qctx : QuoteContext ): Expr [Tuple .InverseMap [T , Expr ]] = {
187- import qctx .tasty .{ _ , given _ }
187+ import qctx .tasty ._
188188 val elems : Seq [Expr [_]] = tup.asInstanceOf [Product ].productIterator.toSeq.asInstanceOf [Seq [Expr [_]]]
189189 ofTuple(elems).cast[Tuple .InverseMap [T , Expr ]]
190190 }
@@ -198,7 +198,7 @@ object Expr {
198198 * @param qctx current context
199199 */
200200 def summon [T ](using tpe : Type [T ])(using qctx : QuoteContext ): Option [Expr [T ]] = {
201- import qctx .tasty .{ _ , given _ }
201+ import qctx .tasty ._
202202 searchImplicit(tpe.unseal.tpe) match {
203203 case iss : ImplicitSearchSuccess => Some (iss.tree.seal.asInstanceOf [Expr [T ]])
204204 case isf : ImplicitSearchFailure => None
0 commit comments