diff --git a/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.kt b/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.kt index 8ca744b73af..6908a19bf36 100644 --- a/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.kt +++ b/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.kt @@ -12,6 +12,7 @@ val test2 = P(1, 2) val test3 = P(1, 2) val test0p2 = P2(1, 1) +val test0p2a = P2(1, "") val test1p2 = P2(1, 1) val test2p2 = P2(1, 1) val test3p2 = P2(1, 1) @@ -21,3 +22,11 @@ val test1pr = PR(1, " val test2pr = PR(1, "") val test2pra = PR(1, "") val test3pr = P2(1, "") + +class Num(val x: T) +typealias N = Num + +val testN0 = N("") +val testN1 = N(1) +val testN1a = N<String>("") +val testN2 = N(1) diff --git a/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.txt b/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.txt index 7b8c401924a..d250dc708f8 100644 --- a/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.txt +++ b/compiler/testData/diagnostics/tests/typealias/wrongNumberOfArgumentsInTypeAliasConstructor.txt @@ -1,10 +1,12 @@ package +public typealias N = Num public typealias P = Pair public typealias P2 = Pair public typealias PR = Pair public val test0: Pair public val test0p2: Pair +public val test0p2a: Pair public val test0pr: Pair public val test1: Pair public val test1p2: Pair @@ -16,6 +18,18 @@ public val test2pra: Pair public val test3: Pair public val test3p2: Pair public val test3pr: Pair +public val testN0: Num +public val testN1: Num +public val testN1a: Num +public val testN2: Num + +public final class Num { + public constructor Num(/*0*/ x: T) + public final val x: T + public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean + public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int + public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String +} public final class Pair { public constructor Pair(/*0*/ x1: T1, /*1*/ x2: T2)