use correct type for vararg value parameter descriptor implementation
diff --git a/compiler-plugin/src/main/kotlin/com/google/devtools/ksp/symbol/impl/binary/KSValueParameterDescriptorImpl.kt b/compiler-plugin/src/main/kotlin/com/google/devtools/ksp/symbol/impl/binary/KSValueParameterDescriptorImpl.kt
index 4d28c8a..705d49a 100644
--- a/compiler-plugin/src/main/kotlin/com/google/devtools/ksp/symbol/impl/binary/KSValueParameterDescriptorImpl.kt
+++ b/compiler-plugin/src/main/kotlin/com/google/devtools/ksp/symbol/impl/binary/KSValueParameterDescriptorImpl.kt
@@ -58,7 +58,12 @@
     }
 
     override val type: KSTypeReference by lazy {
-        KSTypeReferenceDescriptorImpl.getCached(descriptor.type, origin, this)
+        // Descriptor wraps vararg with Array<>, to align with the actual behavior in source.
+        if (isVararg) {
+            KSTypeReferenceDescriptorImpl.getCached(descriptor.varargElementType!!, origin, this)
+        } else {
+            KSTypeReferenceDescriptorImpl.getCached(descriptor.type, origin, this)
+        }
     }
 
     override val hasDefault: Boolean = descriptor.hasDefaultValue()
diff --git a/compiler-plugin/testData/api/allFunctions.kt b/compiler-plugin/testData/api/allFunctions.kt
index 7d65c76..88dca85 100644
--- a/compiler-plugin/testData/api/allFunctions.kt
+++ b/compiler-plugin/testData/api/allFunctions.kt
@@ -75,6 +75,28 @@
 // equals(kotlin.Any): kotlin.Boolean
 // hashCode(): kotlin.Int
 // toString(): kotlin.String
+// class: Sub
+// equals(kotlin.Any): kotlin.Boolean
+// foo(kotlin.String ...): kotlin.Unit
+// hashCode(): kotlin.Int
+// toString(): kotlin.String
+// class: SubAbstract
+// <init>(): SubAbstract
+// equals(kotlin.Any): kotlin.Boolean
+// foo(kotlin.String ...): kotlin.Unit
+// hashCode(): kotlin.Int
+// toString(): kotlin.String
+// class: Super
+// equals(kotlin.Any): kotlin.Boolean
+// foo(kotlin.String ...): kotlin.Unit
+// hashCode(): kotlin.Int
+// toString(): kotlin.String
+// class: SuperAbstract
+// <init>(): SuperAbstract
+// equals(kotlin.Any): kotlin.Boolean
+// foo(kotlin.String ...): kotlin.Unit
+// hashCode(): kotlin.Int
+// toString(): kotlin.String
 // END
 // FILE: a.kt
 abstract class Foo : C(), List<out Number> {
@@ -97,6 +119,20 @@
     }
 }
 
+interface Super {
+    fun foo(vararg values: String)
+}
+
+interface Sub : Super
+
+class SubAbstract: SuperAbstract()
+
+abstract class SuperAbstract {
+    fun foo(vararg values: String) {
+
+    }
+}
+
 // FILE: C.java
 import java.util.Collection;
 
diff --git a/test-utils/src/main/kotlin/com/google/devtools/ksp/processor/AllFunctionsProcessor.kt b/test-utils/src/main/kotlin/com/google/devtools/ksp/processor/AllFunctionsProcessor.kt
index ee25d42..65c682b 100644
--- a/test-utils/src/main/kotlin/com/google/devtools/ksp/processor/AllFunctionsProcessor.kt
+++ b/test-utils/src/main/kotlin/com/google/devtools/ksp/processor/AllFunctionsProcessor.kt
@@ -50,6 +50,9 @@
                         if (it.hasDefault) {
                             append("(hasDefault)")
                         }
+                        if (it.isVararg) {
+                            append(" ...")
+                        }
                     }
                 }.joinToString(",")})" +
                 ": ${this.returnType?.resolve()?.declaration?.qualifiedName?.asString() ?: ""}"