Prohibit recursive inline classes

This commit is contained in:
Dmitry Petrov
2018-08-16 11:30:57 +03:00
parent 4f722dd32d
commit 5045fa446a
9 changed files with 125 additions and 13 deletions
@@ -0,0 +1,16 @@
// !LANGUAGE: +InlineClasses
inline class Test1(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test1<!>)
inline class Test2A(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test2B<!>)
inline class Test2B(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test2A<!>)
inline class Test3A(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test3B<!>)
inline class Test3B(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test3C<!>)
inline class Test3C(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>Test3A<!>)
inline class TestNullable(val x: <!INLINE_CLASS_CANNOT_BE_RECURSIVE!>TestNullable?<!>)
inline class TestRecursionInTypeArguments(val x: List<TestRecursionInTypeArguments>)
inline class TestRecursionInArray(val x: Array<TestRecursionInArray>)