package re; import bf.b0; import bf.k; import java.lang.annotation.Annotation; import java.lang.reflect.Constructor; import java.lang.reflect.Modifier; import java.lang.reflect.Type; import java.lang.reflect.TypeVariable; import java.util.ArrayList; import java.util.List; import kotlin.jvm.internal.s; import ld.i; import ld.q; /* compiled from: ReflectJavaConstructor.kt */ /* loaded from: classes5.dex */ public final class o extends t implements k { /* renamed from: a reason: collision with root package name */ private final Constructor f21936a; public o(Constructor member) { s.e(member, "member"); this.f21936a = member; } /* renamed from: V */ public Constructor T() { return this.f21936a; } @Override // bf.k public List g() { Type[] realTypes = T().getGenericParameterTypes(); s.d(realTypes, "types"); if (realTypes.length == 0) { return q.h(); } Class declaringClass = T().getDeclaringClass(); if (declaringClass.getDeclaringClass() != null && !Modifier.isStatic(declaringClass.getModifiers())) { realTypes = (Type[]) i.j(realTypes, 1, realTypes.length); } Annotation[][] realAnnotations = T().getParameterAnnotations(); if (realAnnotations.length >= realTypes.length) { if (realAnnotations.length > realTypes.length) { s.d(realAnnotations, "annotations"); realAnnotations = (Annotation[][]) i.j(realAnnotations, realAnnotations.length - realTypes.length, realAnnotations.length); } s.d(realTypes, "realTypes"); s.d(realAnnotations, "realAnnotations"); return U(realTypes, realAnnotations, T().isVarArgs()); } throw new IllegalStateException(s.n("Illegal generic signature: ", T())); } @Override // bf.z public List getTypeParameters() { TypeVariable>[] typeParameters = T().getTypeParameters(); s.d(typeParameters, "member.typeParameters"); ArrayList arrayList = new ArrayList(typeParameters.length); int length = typeParameters.length; int i10 = 0; while (i10 < length) { TypeVariable> typeVariable = typeParameters[i10]; i10++; arrayList.add(new a0(typeVariable)); } return arrayList; } }