aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/ast/TreeInfo.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/dotty/tools/dotc/ast/TreeInfo.scala')
-rw-r--r--src/dotty/tools/dotc/ast/TreeInfo.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/ast/TreeInfo.scala b/src/dotty/tools/dotc/ast/TreeInfo.scala
index 6d1c04978..13e10105c 100644
--- a/src/dotty/tools/dotc/ast/TreeInfo.scala
+++ b/src/dotty/tools/dotc/ast/TreeInfo.scala
@@ -27,7 +27,7 @@ trait TreeInfo[T >: Untyped <: Type] { self: Trees.Instance[T] =>
/** Does tree contain an initialization part when seen as a member of a class or trait?
*/
def isNoInitMember(tree: Tree): Boolean = unsplice(tree) match {
- case EmptyTree | Import(_, _) | TypeDef(_, _) => true
+ case EmptyTree | Import(_, _) | TypeDef(_, _) | DefDef(_, _, _, _, _) => true
case tree: ValDef => tree.unforcedRhs == EmptyTree
case _ => false
}