Skip to content

Commit c434949

Browse files
committed
Remove unnecessary tree attachment
1 parent 0896981 commit c434949

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

compiler/src/dotty/tools/dotc/typer/ProtoTypes.scala

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -687,14 +687,8 @@ object ProtoTypes {
687687

688688
/** Dummy tree to be used as an argument of a FunProto or ViewProto type */
689689
object dummyTreeOfType {
690-
/*
691-
* A property indicating that the given tree was created with dummyTreeOfType.
692-
* It is sometimes necessary to detect the dummy trees to avoid unwanted readaptations on them.
693-
*/
694-
val IsDummyTree = new Property.Key[Unit]
695-
696690
def apply(tp: Type)(implicit src: SourceFile): Tree =
697-
(untpd.Literal(Constant(null)) withTypeUnchecked tp).withAttachment(IsDummyTree, ())
691+
untpd.Literal(Constant(null)) withTypeUnchecked tp
698692
def unapply(tree: untpd.Tree): Option[Type] = tree match {
699693
case Literal(Constant(null)) => Some(tree.typeOpt)
700694
case _ => None

0 commit comments

Comments
 (0)