Skip to main content

preprocessor-guard-hygiene

Enforce preprocessor guard rules and macro-dependent inclusion hygiene in C++. Use this skill when modifying conditional imports or preprocessor directives.

来源信息

仓库
google/filament
最近来源活动
2026年5月26日 07:25
检测到的 SKILL.md 语言
英语
星标
20,655
Forks
2,283

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
preprocessor-guard-hygiene
description
Enforce preprocessor guard rules and macro-dependent inclusion hygiene in C++. Use this skill when modifying conditional imports or preprocessor directives.
# Preprocessor Guard Hygiene * **Simple Guarded Includes:** Headers wrapped inside single-line preprocessor guards (like `#if __EXCEPTIONS` or `#if defined(__ARM_NEON)`) must remain wrapped and are sorted alphabetically within their correct layer. * **Macro-Dependent Templating:** Never modify or split includes that are tightly coupled with macro configurations (such as `#define UTILS_PRIVATE_IMPLEMENTATION_NON_COPYABLE` in `ostream.cpp`). The `reorganize_headers.py` safety check will automatically detect and skip these; respect these skips.
在 GitHub 查看