Skip to content

Commit e75cafe

Browse files
committed
Remove unnecessary widening
1 parent 37200be commit e75cafe

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

compiler/src/dotty/tools/dotc/transform/Splicing.scala

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -391,9 +391,7 @@ class Splicing extends MacroTransform:
391391
Splice(closure, tpe)
392392

393393
private def quoted(expr: Tree)(using Context): Tree =
394-
untpd.Quote(expr).withBodyType(expr.tpe.widenTermRefExpr) // TODO do we need widenTermRefExpr?
395-
.select(nme.apply)
396-
.appliedTo(quotes.nn)
394+
tpd.Quote(expr).select(nme.apply).appliedTo(quotes.nn)
397395

398396
/** Helper methods to construct trees calling methods in `Quotes.reflect` based on the current `quotes` tree */
399397
private object reflect extends ReifiedReflect {

0 commit comments

Comments
 (0)