Support [throws] annotation

This commit is contained in:
Andrey Breslav
2014-01-22 15:37:27 +04:00
parent b66a76e7d2
commit 4ab0b00bd3
17 changed files with 284 additions and 7 deletions
@@ -0,0 +1,21 @@
class E1: Exception()
class E2: Exception()
trait Trait {
throws()
fun none()
throws(javaClass<E1>())
fun one()
throws(javaClass<E1>(), javaClass<E2>())
fun two()
}
class Impl: Trait {
override fun none() {}
override fun one() {}
override fun two() {}
}
class Test: Trait by Impl()