public Expression transform(UnaryMinusExpression exp, CompilerTransformer compiler) {
    final BytecodeExpr inner = (BytecodeExpr) compiler.transform(exp.getExpression());
    final ClassNode type = ClassHelper.getUnwrapper(inner.getType());
    if (type == ClassHelper.byte_TYPE
        || type == ClassHelper.short_TYPE
        || type == ClassHelper.int_TYPE
        || type == ClassHelper.long_TYPE
        || type == ClassHelper.float_TYPE
        || type == ClassHelper.double_TYPE) {
      return new BytecodeExpr(exp, type) {
        protected void compile(MethodVisitor mv) {
          inner.visit(mv);
          if (!ClassHelper.isPrimitiveType(inner.getType())) unbox(type, mv);

          if (type == ClassHelper.int_TYPE
              || type == ClassHelper.short_TYPE
              || type == ClassHelper.byte_TYPE) mv.visitInsn(INEG);
          else if (type == ClassHelper.long_TYPE) mv.visitInsn(LNEG);
          else if (type == ClassHelper.float_TYPE) mv.visitInsn(FNEG);
          else if (type == ClassHelper.double_TYPE) mv.visitInsn(DNEG);
        }
      };
    } else {
      MethodCallExpression negate =
          new MethodCallExpression(inner, "negate", new ArgumentListExpression());
      negate.setSourcePosition(exp);
      return compiler.transform(negate);
    }
  }
 public void visitUnaryMinusExpression(UnaryMinusExpression expression) {
   expression.getExpression().visit(this);
 }