Skip to content

Commit b00335f

Browse files
Update compiler/src/dotty/tools/dotc/ast/tpd.scala
Co-authored-by: odersky <odersky@gmail.com>
1 parent 3375ba3 commit b00335f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

compiler/src/dotty/tools/dotc/ast/tpd.scala

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1251,7 +1251,9 @@ object tpd extends Trees.Instance[Type] with TypedTreeInfo {
12511251

12521252
/** Check if the limit on the number of inlined trees has been reached */
12531253
def reachedInlinedTreesLimit(implicit ctx: Context): Boolean =
1254-
ctx.property(InlinedTrees).fold(0)(_.count) > ctx.settings.XmaxInlinedTrees.value
1254+
ctx.property(InlinedTrees) match
1255+
case Some(n) => n > ctx.settings.XmaxInlinedTrees.value
1256+
case None => false
12551257

12561258
/** The source file where the symbol of the `inline` method referred to by `call`
12571259
* is defined

0 commit comments

Comments
 (0)