Published-api checker refactoring, support java package-protected visibility

This commit is contained in:
Mikhael Bogdanov
2016-12-19 13:58:38 +01:00
parent 0fa2c54ae8
commit 6ca1d47207
4 changed files with 108 additions and 19 deletions
@@ -15,7 +15,7 @@ fun <T> javaClass(): Class<T> = null!!
public class AppServiceModule : AbstractModule<String>() {
inline fun <reified T> AbstractModule<Int>.bind() {
val x = bind(javaClass<T>())
val x = <!PROTECTED_CALL_FROM_PUBLIC_INLINE!>bind<!>(javaClass<T>())
x checkType { _<String>() } // check that Class receiver is used instead of extension one
}