{"record":{"id":"3ec838f378cd800b","repo":"go-delve/delve","slug":"backend-does-not-support-function-calls","errorCode":null,"errorMessage":"backend does not support function calls","messagePattern":"backend does not support function calls","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/proc/fncall.go","lineNumber":60,"sourceCode":"//\n//  - evalop.CallInjectionStart\n//  - evalop.CallInjectionSetTarget\n//  - evalCallInjectionCopyArg\n//  - evalCallInjectionComplete\n//\n// When the target has runtime.debugPinner then evalCallInjectionPinPointer\n// must be also called in a loop until it returns false.\n\nconst (\n\tdebugCallFunctionNamePrefix1 = \"debugCall\"\n\tdebugCallFunctionNamePrefix2 = \"runtime.debugCall\"\n\tmaxDebugCallVersion          = 2\n\tmaxArgFrameSize              = 65535\n)\n\nvar (\n\terrFuncCallUnsupported        = errors.New(\"function calls not supported by this version of Go\")\n\terrFuncCallUnsupportedBackend = errors.New(\"backend does not support function calls\")\n\terrFuncCallInProgress         = errors.New(\"cannot call function while another function call is already in progress\")\n\terrNoGoroutine                = errors.New(\"no goroutine selected\")\n\terrGoroutineNotRunning        = errors.New(\"selected goroutine not running\")\n\terrNotEnoughStack             = errors.New(\"not enough stack space\")\n\terrTooManyArguments           = errors.New(\"too many arguments\")\n\terrNotEnoughArguments         = errors.New(\"not enough arguments\")\n\terrNotAGoFunction             = errors.New(\"not a Go function\")\n\terrFuncCallNotAllowedStrAlloc = errors.New(\"literal string can not be allocated because function calls are not allowed without using 'call'\")\n)\n\ntype functionCallState struct {\n\t// savedRegs contains the saved registers\n\tsavedRegs Registers\n\t// err contains a saved error\n\terr error\n\t// expr is the expression being evaluated\n\texpr *ast.CallExpr\n\t// fn is the function that is being called","sourceCodeStart":42,"sourceCodeEnd":78,"githubUrl":"https://github.com/go-delve/delve/blob/a23773e6c31361e43246bc43a424ee009679b174/pkg/proc/fncall.go#L42-L78","documentation":"errFuncCallUnsupportedBackend indicates the selected debugging backend (e.g. core dump analysis, or a backend lacking the required primitives) cannot perform function-call injection, independent of the Go version. Returned by EvalExpressionWithCalls and evalCallInjectionStart in pkg/proc/fncall.go.","triggerScenarios":"Requesting a function call while debugging a core dump (pkg/proc/core) or through a backend that has not implemented call injection; the 'call' command in a session that is not attached to a live native process.","commonSituations":"Trying 'call' while analyzing a core dump; remote/gdbserial sessions without call support; scripts that run the same eval set against both live and postmortem targets.","solutions":["Attach to or launch a live process with the native backend instead of examining a core dump","Remove function calls from postmortem analysis workflows; use variable evaluation only","Check backend capabilities before scripting 'call' commands"],"exampleFix":"// before\ndlv core ./app core.dump\ndlv> call foo(1)\n// after\ndlv exec ./app\ndlv> call foo(1)","handlingStrategy":"validation","validationCode":"// only issue function calls on a live native process, never against core dumps\n// dlv exec ./app  (good)   vs   dlv core ./app core (no calls)","typeGuard":null,"tryCatchPattern":"if errors.Is(err, proc.ErrFuncCallUnsupportedBackend) {\n    // switch to live-process debugging or drop the call from the workflow\n}","preventionTips":["Never use 'call' in core-dump analysis sessions","Gate scripted 'call' commands on the session type (exec/attach, not core)","Document backend capabilities in tooling that issues evaluations"],"tags":["go","function-call","backend","core-dump"],"backgroundTag":"func-call-unsupported-backend","analyzedSha":"a23773e6c31361e43246bc43a424ee009679b174","analyzedAt":"2026-08-31T15:12:45.221Z","schemaVersion":2},"datasetVersion":"2026-08-31T19:17:28.585Z"}