[FIR] KT-46483: Forbid annotations in where Clauses

Merge-request: KT-MR-7208
Merged-by: Nikolay Lunyak <lunyak.kolya@mail.ru>
This commit is contained in:
Nikolay Lunyak
2022-09-28 13:38:18 +00:00
committed by Space
parent a20ce06102
commit f578381726
37 changed files with 462 additions and 20 deletions
@@ -9,4 +9,4 @@ abstract class Bar<T : @Ann(<!UNRESOLVED_REFERENCE!>unresolved_reference<!>) Any
* TESTCASE NUMBER: 2
* UNEXPECTED BEHAVIOUR
*/
class B<T> where @Ann(unresolved_reference) T : Number
class B<T> where <!ANNOTATION_IN_WHERE_CLAUSE_ERROR, WRONG_ANNOTATION_TARGET!>@Ann(<!UNRESOLVED_REFERENCE!>unresolved_reference<!>)<!> T : Number
@@ -18,4 +18,4 @@ abstract class Bar<T : @Ann(<!UNRESOLVED_REFERENCE!>unresolved_reference<!>) Any
* TESTCASE NUMBER: 2
* UNEXPECTED BEHAVIOUR
*/
class B<T> where @<!DEBUG_INFO_MISSING_UNRESOLVED!>Ann<!>(<!DEBUG_INFO_MISSING_UNRESOLVED!>unresolved_reference<!>) T : Number
class B<T> where <!ANNOTATION_IN_WHERE_CLAUSE_WARNING!>@<!DEBUG_INFO_MISSING_UNRESOLVED!>Ann<!>(<!DEBUG_INFO_MISSING_UNRESOLVED!>unresolved_reference<!>)<!> T : Number