diff --git a/gradle.properties b/gradle.properties
index 3ddf1b4a..19f5622d 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -4,5 +4,5 @@ packaging=jar
description=Mixin
url=https://www.spongepowered.org
organization=SpongePowered
-buildVersion=0.7.7
+buildVersion=0.7.8
buildType=SNAPSHOT
diff --git a/src/main/java/org/spongepowered/asm/launch/MixinBootstrap.java b/src/main/java/org/spongepowered/asm/launch/MixinBootstrap.java
index a1e94a16..39d6dd04 100644
--- a/src/main/java/org/spongepowered/asm/launch/MixinBootstrap.java
+++ b/src/main/java/org/spongepowered/asm/launch/MixinBootstrap.java
@@ -60,7 +60,7 @@ public abstract class MixinBootstrap {
/**
* Subsystem version
*/
- public static final String VERSION = "0.7.7";
+ public static final String VERSION = "0.7.8";
/**
* Log all the things
diff --git a/src/main/java/org/spongepowered/asm/mixin/injection/invoke/arg/ArgsClassGenerator.java b/src/main/java/org/spongepowered/asm/mixin/injection/invoke/arg/ArgsClassGenerator.java
index afef515d..1af10490 100644
--- a/src/main/java/org/spongepowered/asm/mixin/injection/invoke/arg/ArgsClassGenerator.java
+++ b/src/main/java/org/spongepowered/asm/mixin/injection/invoke/arg/ArgsClassGenerator.java
@@ -107,19 +107,16 @@ public final class ArgsClassGenerator implements IClassGenerator {
* will not be generated until it is used. Calling this method simply
* allocates a name for the specified descriptor.
*
- * @param desc Descriptor of the target method, with the return
- * type changed to void (V)
+ * @param desc Descriptor of the target method, the return type is
+ * ignored for the purposes of generating Args subclasses
* @return name of the Args subclass to use
*/
public String getClassName(String desc) {
- if (!desc.endsWith(")V")) {
- throw new IllegalArgumentException("Invalid @ModifyArgs method descriptor");
- }
-
- String name = this.classNames.get(desc);
+ String voidDesc = Bytecode.changeDescriptorReturnType(desc, "V");
+ String name = this.classNames.get(voidDesc);
if (name == null) {
name = String.format("%s%d", ArgsClassGenerator.CLASS_NAME_BASE, this.nextIndex++);
- this.classNames.put(desc, name);
+ this.classNames.put(voidDesc, name);
}
return name;
}
@@ -263,9 +260,10 @@ public final class ArgsClassGenerator implements IClassGenerator {
for (Type arg : args) {
of.visitInsn(Opcodes.DUP);
of.visitConstant(argIndex);
- of.visitVarInsn(arg.getOpcode(Opcodes.ILOAD), argIndex++);
+ of.visitVarInsn(arg.getOpcode(Opcodes.ILOAD), argIndex);
ArgsClassGenerator.box(of, arg);
of.visitInsn(Opcodes.AASTORE);
+ argIndex += arg.getSize();
}
// Call the constructor passing in the generated array