Skip to content

Commit 6194020

Browse files
committed
PatMat: remove one more trace of doing several steps at a time
When creating subPatRefs the consider returned type of accessor, not the type of binder. Fixes #1114
1 parent 07bf063 commit 6194020

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/dotty/tools/dotc/transform/PatternMatcher.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1543,7 +1543,7 @@ class PatternMatcher extends MiniPhaseTransform with DenotTransformer {thisTrans
15431543
val spb = subPatBinders
15441544
ExtractorTreeMaker(extractorApply, lengthGuard(binder), binder)(
15451545
spb,
1546-
subPatRefs(binder, spb, binderTypeTested),
1546+
subPatRefs(binder, spb, resultType),
15471547
aligner.isBool,
15481548
checkedLength,
15491549
patBinderOrCasted,

0 commit comments

Comments
 (0)