Skip to content

Commit e1873d4

Browse files
committed
Add case for FlexibleType
1 parent 3f10858 commit e1873d4

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

compiler/src/scala/quoted/runtime/impl/QuotesImpl.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1912,6 +1912,7 @@ class QuotesImpl private (using val ctx: Context) extends Quotes, QuoteUnpickler
19121912
def typeArgs: List[TypeRepr] = self match
19131913
case AppliedType(_, args) => args
19141914
case AnnotatedType(parent, _) => parent.typeArgs
1915+
case FlexibleType(underlying) => underlying.typeArgs
19151916
case _ => List.empty
19161917
end extension
19171918
end TypeReprMethods

tests/new/test.scala

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
1-
class Cap extends caps.ExclusiveCapability
1+
object e:
2+
def foldRL(f: Int => Int)(g: String => Int) = ???
3+
4+
5+
val xs = e.foldRL
6+
: i => i + 1
7+
: s => s.length
28

3-
def test(consume x: Cap) = ???
49

5-
def impl(using consume x: Cap) = ???

0 commit comments

Comments
 (0)