一键导入
c-code
Guidance for editing C code in tibblify. Use when working in src/, adding C functions, or touching the C/R interface.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Guidance for editing C code in tibblify. Use when working in src/, adding C functions, or touching the C/R interface.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Document package functions. Use when asked to document functions.
Creates GitHub issues for the package repository. Use when asked to create, file, or open a GitHub issue, or when planning new features or functions that need to be tracked.
Test-driven development workflow. Use when writing any R code (writing new features, fixing bugs, refactoring, or reviewing tests).
Identify likely GitHub issues connected to test cases. Use when asked to tag tests with issues or get started with qcthat.
| name | c-code |
| description | Guidance for editing C code in tibblify. Use when working in src/, adding C functions, or touching the C/R interface. |
src/ — tibblify's C code. Edit freely.src/rlang/ — vendored rlang C API. Do not edit directly.src/rlang-rcc.cpp and src/rlang.c — include points for vendored rlang. Do not edit directly.| File | Purpose |
|---|---|
collector.h / collector.c | Collector structs — the core data structure |
add-value.h / add-value.c | Adding values to collectors during parsing |
parse-spec.h / parse-spec.c | Parsing tib_*() spec objects from R |
tibblify.c | .Call() entry points |
init.c | R_registerRoutines / R_useDynamicSymbols |
finalize.c | Finalizing collectors into output |
devtools::load_all() compiles automatically. For a clean rebuild:
pkgbuild::compile_dll(debug = TRUE)
src/rlang/ (e.g. rlang/rlang.h).
PKG_CPPFLAGS = -I./rlang is set in Makevars.LinkingTo: vctrs; use vctrs/vctrs.h..h file.R_CallMethodDef CallEntries[] in init.c..Call() in the appropriate R/ file.document skill.Makevars sets -fvisibility=hidden. Only symbols listed in CallEntries
are public — all other symbols are hidden by default.
All C code is tested through R wrappers in tests/testthat/. There are no
standalone C tests; write R-level tests for every new C function.
Updating src/rlang/ is handled by the rlang-c.yaml workflow. To update
manually, follow that workflow — do not hand-edit files in src/rlang/.