File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
compiler/src/scala/quoted/runtime/impl Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -244,9 +244,12 @@ object QuoteMatcher {
244244 case Select (qual2, _) if symbolMatch(scrutinee, pattern) =>
245245 ref match
246246 case Select (qual1, _) => qual1 =?= qual2
247- case ref : Ident if qual2.symbol == defn.QuotedRuntimePatterns_patternHole =>
248- tpd.desugarIdentPrefix(ref) =?= qual2
249- case ref : Ident => matched
247+ case ref : Ident =>
248+ if qual2.existsSubTree(_.symbol == defn.QuotedRuntimePatterns_patternHole ) then
249+ // Prefix has a hole, so we need to match the prefix to extract the value of the hole
250+ tpd.desugarIdentPrefix(ref) =?= qual2
251+ else
252+ matched
250253
251254 /* Match reference */
252255 case _ : Ident if symbolMatch(scrutinee, pattern) => matched
You can’t perform that action at this time.
0 commit comments