# Go: not enough arguments in call to f have (int) want (int, string)

**Code:** `not enough / too many arguments in call` · **Category:** Go · **Seen on:** Go

A function was called with fewer or more arguments than it declares.

## Meaning

Compare the call with the function signature; the error shows `have` and `want`. After changing a function signature, update all call sites. For variadic functions use `args...` to pass a slice.

## Common causes

- Signature changed but callers not updated
- Forgot an argument (context.Context, error handling)
- Extra argument passed
- Method vs function confusion
- Variadic slice not expanded

## Quick fix

1. Match the call to `want (…)`
2. Update all callers after changing the signature
3. Use `f(items...)` for variadic parameters

## Detailed fix by platform

### Go

1. Use `gopls` rename/change-signature refactoring in your editor to update call sites

## How to diagnose

1. **Have/want** — Compare lists?
2. **Signature** — Recently changed?
3. **Variadic** — Expanded?

---
Source: [WhatIsMyError](https://whatismyerror.com/errors/go/wrong-argument-count)
