Skip to content

String index out of range during AP #560

@shedaniel

Description

@shedaniel

With the fix to #518 (1e1aa7f), Mixin tries to pretty print a field (asm field) with SignaturePrinter (works only with methods)

This doesn't crash in Mixin 0.8.4.

Type.getReturnType(desc) and Type.getArgumentTypes(desc): Expects a description with ):

this(name, Type.getReturnType(desc), Type.getArgumentTypes(desc));

TypeUtils uses it:

return new SignaturePrinter("", descriptor).setFullyQualified(true).toDescriptor();

TypeHandleASM uses it for anonymous classes for fields:

if (TypeHandleASM.compareElement(field.name, TypeUtils.getJavaSignature(field.desc), name, type, matchCase)) {

Mixin: (0.8.5 on 1.18 ForgeGradle)

@Mixin(targets = "net.minecraft.server.level.ServerPlayer$2")
public class ServerPlayerEntityMixin {
    @Shadow
    ServerPlayer f_143458_;
}

idea64_enUUjZVbyA

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions