MCPInstall

c-bounds-safety

Guide for the C -fbounds-safety language extension. Covers the language model, pointer annotations, adopting bounds-safety in existing C code, compiler build settings and modes, and runtime debugging of bounds violations.

Installs
625
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/superagents-lab/xcode27-skills --skill c-bounds-safety
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads c-bounds-safety automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

How to Use This Skill

When helping with -fbounds-safety adoption or code changes, ask clarifying questions about the user's codebase and goals before suggesting changes. For complex tasks involving multiple files or non-trivial annotation decisions, use plan mode to propose an approach before implementing.

-fbounds-safety Language Extension

-fbounds-safety is a C language extension that prevents out-of-bounds memory access by enforcing bounds safety at the language level. It inserts automatic bounds checks at runtime, rejects unsafe pointer operations at compile time, and requires programmers to provide bounds annotations so the compiler can guarantee safety. Out-of-bounds accesses become deterministic traps instead of exploitable vulnerabilities.

Detailed Documentation

Required reading before adoption work

You MUST have fully read the following three documents (via the Read tool) at the start of an adoption task, and re-read them via the Read tool before any source-modifying step in the adoption workflow unless their content is verifiably fresh in your active context:

  • adoption-strategies.md — the workflow for adopting -fbounds-safety in an existing C project (full and header-only modes).
  • language-overview.md — the language reference for -fbounds-safety: pointer kinds, annotations, and the rules that govern them.
  • common-patterns-and-pitfalls.md — recipes and anti-patterns encountered during real-world adoption.

Other references (read on demand)

For compiler flags, Xcode build settings, soft trap mode, and ptrcheck.h configuration, read build-settings.md.

For debugging bounds violations at runtime — trap behavior, LLDB commands, wide pointer inspection, watchpoints, crash log analysis, and soft trap debugging, read runtime-debugging.md.

FAQ

What does the c-bounds-safety skill do?

Guide for the C -fbounds-safety language extension. Covers the language model, pointer annotations, adopting bounds-safety in existing C code, compiler build settings and modes, and runtime debugging of bounds violations.

How do I install c-bounds-safety?

Run npx skills add https://github.com/superagents-lab/xcode27-skills --skill c-bounds-safety in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/c-bounds-safety/ (personal) or .claude/skills/c-bounds-safety/ (project).

Which AI agents can use c-bounds-safety?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is c-bounds-safety safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains c-bounds-safety?

It is published by superagents-lab in superagents-lab/xcode27-skills. It has 625 recorded installs.

More from superagents-lab/xcode27-skills

View all →

swiftui-specialist

superagents-lab/xcode27-skills

Best practices and idiomatic patterns for SwiftUI. Use when writing, reviewing, or editing SwiftUI code.

Mobile866 installs

device-interaction

superagents-lab/xcode27-skills

Verify iOS app behavior on device or simulator via screenshots, UI hierarchy, and touch interactions.

Frontend & Design742 installs

swiftui-whats-new-27

superagents-lab/xcode27-skills

New SwiftUI APIs, behaviors, and deprecations introduced in the 2027 OS releases (iOS 27, macOS 27, watchOS 27, tvOS 27, visionOS 27). Use when a SwiftUI view using @State fails to compile with "used before being initialized", "invalid redeclaration of synthesized property", or "extraneous argument label" errors after an SDK update (@State migrated from a property wrapper to a macro in SDK 27; the obvious fix of reordering init assignments is WRONG and produces incorrect runtime behavior; you MUST consult this skill's references before answering); when @ViewBuilder or @ContentBuilder code hits ambiguous overloads in overlay/background or type-check performance regressions after an SDK update; when the user asks what's new in SwiftUI (generally, or for a specific 2027 platform); when adding drag-to-reorder to any container (List, LazyVStack, LazyVGrid, stacks, or custom layouts) via reorderable()/reorderContainer, including the drag-and-drop that integrates with it (dragContainer, dropD

Mobile739 installs

test-modernizer

superagents-lab/xcode27-skills

Modernize test suites to use modern Swift Testing features or migrate from XCTest.

Testing & QA698 installs

audit-xcode-security-settings

superagents-lab/xcode27-skills

Audit and enable security-oriented Xcode build settings. Progressively enables compiler warnings, static analyzer checkers, and Enhanced Security features. Use when: user wants to secure their Xcode project, audit security settings, enable hardening, review security posture of build configuration, set up security-focused static analysis, enable static analysis, improve warning coverage, harden diagnostics, or catch more bugs at compile time in C/C++/Objective-C/Swift. SKIP: network security (TLS/ATS), code signing, privacy APIs.

Security698 installs

uikit-app-modernization

superagents-lab/xcode27-skills

Modernizes UIKit apps for multi-window environments by replacing legacy shared-state APIs with context-appropriate modern alternatives. This includes references to mainScreen, interfaceOrientation, application and scene lifecycle, as well as safe area inset updates.

691 installs

Popular code quality & workflow skills

View category →

grill-me

mattpocock/skills

A relentless interview to sharpen a plan or design.

Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

handoff

mattpocock/skills

Compact the current conversation into a handoff document for another agent to pick up.

domain-modeling

mattpocock/skills

Build and sharpen a project's domain model. Use when discussing codebase terminology, writing or editing a GLOSSARY.md, or recording or editing an ADR.

codebase-design

mattpocock/skills

Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.

diagnosing-bugs

mattpocock/skills

Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.