go-nil-interface

Detect typed nil values stored in Go interfaces.

3|Updated Nov 28, 2025
One-click install
npx skills add https://github.com/JamesPrial/claudefiles --skill go-nil-interface
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: go-nil-interface
Source: https://github.com/JamesPrial/claudefiles/tree/main/skills/golang/nil/interface
Command: npx skills add https://github.com/JamesPrial/claudefiles --skill go-nil-interface

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

A typed nil stored in an interface is not nil, which can lead to surprising errors if not handled.

Core Features & Use Cases

  • Typed Nil Handling: Return untyped nil or handle nil receivers safely.
  • Practical Examples: Clear CORRECT vs WRONG patterns for common interfaces.

Quick Start

Refactor a function returning errors to ensure nil is untyped when appropriate.