go-delve/delve · error

no address specified

Error message

no address specified

What it means

After flag parsing, ParseExamineMemoryArg requires a non-empty Operand: the address or expression whose memory should be examined. If the command contained only flags (or nothing at all), Delve returns this error.

Solutions

  1. Include an address or expression, e.g. `x -count 4 -size 8 0xc000010000` or `x &myVar`
  2. Check the client sends a valid memory reference; for variables without an address, skip the request
  3. Verify optimized-out or register-allocated variables aren't being passed as operands

Example fix

// before
s.examineMemory(ctx, "x -count 4 -size 8")
// after
s.examineMemory(ctx, "x -count 4 -size 8 0xc000010000")
Defensive patterns

Strategy: validation

Validate before calling

if strings.TrimSpace(operand) == "" {
	return // do not issue examineMemory without an address/expression
}

Prevention

When it happens

Trigger: `examineMemory` calls with an empty argument string, with only flags such as `x -count 4 -size 8`, or where the address argument was consumed by `-x` handling but evaluated to an empty expression.

Common situations: IDEs that send the request before the user typed an address; variables panel drivers that pass an empty expression for values without an address (e.g. optimized-out variables, register-only values).

Understand the failure class

Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.

Related errors


AI-assisted analysis of go-delve/delve@a23773e6c3 (2026-08-31). Data as JSON: /api/errors/ded4c1180e171329. Report an issue: GitHub.

Appendix: source

Thrown at service/api/command.go:271

			if err != nil || out.Size <= 0 || out.Size > 8 {
				return nil, errors.New("size must be a positive integer (<=8)")
			}
		case "-x":
			out.IsExpr = true
			// remaining args are going to be interpreted as expression
			out.Operand = strings.Join(args, " ")
			break loop
		default:
			if len(args) > 0 {
				return nil, fmt.Errorf("unknown option %q", args[0])
			}
			out.Operand = cmd
			break loop // only one arg left to be evaluated as a uint
		}
	}

	if len(out.Operand) == 0 {
		return nil, errors.New("no address specified")
	}

	return &out, nil
}

View on GitHub (pinned to a23773e6c3)