Do not add container annotaions to type artificially

It was only used for type-related nullability/mutability
annotations and it was necessary to remove them
in the descriptor renderer (duplicating their fqnames there).
At the same time they're only needed for types enhancement
where they can be simply restored from type owners' descriptors

The testData changes are more or less correct: this kind of annotations
is bound both to types themselves and their use because of their targets
This commit is contained in:
Denis Zharkov
2017-06-16 14:50:13 +03:00
parent f877c82029
commit 57b7b91444
18 changed files with 84 additions and 139 deletions
@@ -4,10 +4,10 @@ public fun main(/*0*/ a: A): kotlin.Unit
public open class A {
public constructor A()
@MyNullable public final var field: @MyNullable kotlin.String?
@MyNonnull public open fun bar(): @MyNonnull kotlin.String
@MyNullable public final var field: kotlin.String?
@MyNonnull public open fun bar(): kotlin.String
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
@MyNullable public open fun foo(/*0*/ @MyNonnull x: @MyNonnull kotlin.String, /*1*/ @MyNullable y: @MyNullable kotlin.CharSequence?): @MyNullable kotlin.String?
@MyNullable public open fun foo(/*0*/ @MyNonnull x: kotlin.String, /*1*/ @MyNullable y: kotlin.CharSequence?): kotlin.String?
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}