diff options
Diffstat (limited to 'tests/untried/pos/annotDepMethType.scala')
-rw-r--r-- | tests/untried/pos/annotDepMethType.scala | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/untried/pos/annotDepMethType.scala b/tests/untried/pos/annotDepMethType.scala new file mode 100644 index 000000000..079ca6224 --- /dev/null +++ b/tests/untried/pos/annotDepMethType.scala @@ -0,0 +1,7 @@ +case class pc(calls: Any*) extends annotation.TypeConstraint + +object Main { + class C0 { def baz: String = "" } + class C1 { def bar(c0: C0): String @pc(c0.baz) = c0.baz } + def trans(c1: C1): String @pc(c1.bar(throw new Error())) = c1.bar(new C0) +} |