From 96c5efac3e6af44ea3bcf677c12d0a45d172bafa Mon Sep 17 00:00:00 2001 From: odersky Date: Sat, 29 Oct 2022 19:44:59 +0200 Subject: [PATCH 1/2] test case --- tests/run/i16252.scala | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 tests/run/i16252.scala diff --git a/tests/run/i16252.scala b/tests/run/i16252.scala new file mode 100644 index 000000000000..8c53e689febe --- /dev/null +++ b/tests/run/i16252.scala @@ -0,0 +1,10 @@ +class Baz: + transparent inline def foo: Int = bar(zero) + transparent inline def bar(inline i: Int): Int = inline i match + case 0 => 0 + case _ => scala.compiletime.error("XD") + private transparent inline def zero = 0 + +@main +def main = + println(Baz().foo) \ No newline at end of file From 1f3618fa7eca0d48eb79a2ac34df34f763a53dab Mon Sep 17 00:00:00 2001 From: odersky Date: Sun, 30 Oct 2022 17:51:57 +0100 Subject: [PATCH 2/2] Update tests/run/i16252.scala Co-authored-by: Dale Wijnand --- tests/run/i16252.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/run/i16252.scala b/tests/run/i16252.scala index 8c53e689febe..df08a32b0ff1 100644 --- a/tests/run/i16252.scala +++ b/tests/run/i16252.scala @@ -6,5 +6,5 @@ class Baz: private transparent inline def zero = 0 @main -def main = +def Test = println(Baz().foo) \ No newline at end of file