We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d4e477c commit d2b2dddCopy full SHA for d2b2ddd
compiler/src/dotty/tools/dotc/parsing/Parsers.scala
@@ -2961,7 +2961,7 @@ object Parsers {
2961
if in.token == RPAREN && !prefix && !impliedMods.is(Given) then Nil
2962
else
2963
val clause =
2964
- if prefix && !isIdent(nme.using) then param() :: Nil
+ if prefix && !isIdent(nme.using) && !isIdent(nme.erased) then param() :: Nil
2965
2966
paramMods()
2967
if givenOnly && !impliedMods.is(Given) then
tests/pos/i11743.scala
@@ -0,0 +1,8 @@
1
+import language.experimental.erasedTerms
2
+import scala.compiletime.erasedValue
3
+type UnivEq[A]
4
+object UnivEq:
5
+ erased def force[A]: UnivEq[A] = erasedValue
6
+ extension [A](erased proof: UnivEq[A])
7
+ inline def univEq(a: A, b: A): Boolean =
8
+ a == b
0 commit comments