Skip to content

Commit 9e79fff

Browse files
committed
wip
1 parent 447dd7c commit 9e79fff

File tree

3 files changed

+5
-19
lines changed

3 files changed

+5
-19
lines changed

compiler/src/dotty/tools/dotc/transform/PCPCheckAndHeal.scala

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ class PCPCheckAndHeal(@constructorOnly ictx: Context) extends TreeMapWithStages(
6868
checkAnnotations(tree)
6969
super.transform(tree)
7070
else tree match {
71-
7271
case _: TypeTree | _: RefTree if tree.isType =>
7372
val healedType = healType(tree.sourcePos)(tree.tpe)
7473
if healedType == tree.tpe then tree

compiler/src/dotty/tools/dotc/transform/TreeMapWithStages.scala

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,14 +102,17 @@ abstract class TreeMapWithStages(@constructorOnly ictx: Context) extends TreeMap
102102

103103
tree match {
104104
case TypeApply(Select(Select(scope, _) ,nme.apply), List(quotedTree)) if tree.symbol.isQuote =>
105+
val old = inQuoteOrSplice
106+
inQuoteOrSplice = true
105107
currentScope = scope
106-
dropEmptyBlocks(quotedTree) match
108+
try dropEmptyBlocks(quotedTree) match
107109
case SplicedType(t) =>
108110
// '[ x.$splice ] --> x
109111
transform(t)
110112
case _ =>
111113
transformQuotation(quotedTree, tree)
112-
case Apply(Select(Quoted(quotedTree), _), List(scope)) if quotedTree.isType =>
114+
finally inQuoteOrSplice = old
115+
case Apply(Select(Quoted(quotedTree), _), List(scope)) if quotedTree.isType => // TODO remove?
113116
currentScope = scope
114117
dropEmptyBlocks(quotedTree) match
115118
case SplicedType(t) =>

library/src-bootstrapped/scala/quoted/Scope.scala

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -198,35 +198,20 @@ trait Scope extends Liftables, Unliftables { self =>
198198

199199

200200
// tests/neg-macros/i4044b.scala failed
201-
// tests/neg-macros/i7013.scala failed
202-
// tests/neg-macros/i7013b.scala failed
203-
// tests/neg-macros/i7013c.scala failed
204-
// tests/neg-macros/i7892.scala failed
205201
// tests/neg-macros/quotedPatterns-1.scala failed
206202
// tests/pos-macros/i4414.scala failed
207-
// tests/pos-macros/i6140.scala failed
208-
// tests/pos-macros/i6142.scala failed
209-
// tests/pos-macros/i6210 failed
210-
// tests/pos-macros/i7358.scala failed
211203
// tests/pos-macros/i7405.scala failed
212204
// tests/pos-macros/i7405b.scala failed
213205
// tests/pos-macros/i8100.scala failed
214206
// tests/pos-macros/i8302.scala failed
215207
// tests/pos-macros/quoted-pattern-type.scala failed
216208
// tests/pos-macros/return-quoted.scala failed
217209
// tests/pos-macros/toexproftuple.scala failed
218-
// tests/pos-macros/typetags.scala failed
219210
// tests/run-macros/f-interpolation-1 failed
220211
// tests/run-macros/i5941 failed
221-
// tests/run-macros/i7008 failed
222212
// tests/run-macros/i7987 failed
223213
// tests/run-macros/i8007 failed
224-
// tests/run-macros/i8520 failed
225-
// tests/run-macros/quote-implicitMatch failed
226-
// tests/run-macros/quote-toExprOfTuple failed
227214
// tests/run-macros/quoted-pattern-type failed
228-
// tests/run-macros/refined-selectable-macro failed
229-
// tests/run-macros/string-context-implicits failed
230215
// tests/run-macros/xml-interpolation-1 failed
231216
// tests/run-macros/xml-interpolation-2 failed
232217

@@ -236,7 +221,6 @@ trait Scope extends Liftables, Unliftables { self =>
236221
// tests/run-staging/i3876.scala failed
237222
// tests/run-staging/i4044b.scala failed
238223
// tests/run-staging/i4730.scala failed
239-
// tests/run-staging/i5247.scala failed
240224
// tests/run-staging/i6754.scala failed
241225
// tests/run-staging/multi-staging.scala failed
242226
// tests/run-staging/quote-nested-4.scala failed

0 commit comments

Comments
 (0)