[Rosetta-9] Modernize C, C++, Clang and toolchains
Maintainers usually reply within 1 day
@k5602 is already working on this.
Since Sep 6, 2026.
Assessment
This issue has not been assessed yet.
Description
Goal
Unify compiler baselines. Update format and lint. Fix old Find modules. Document toolchain per tier.
Known debt
cmake/CompileOptions.cmake:37-59gates GNU 4.9 plus, Clang 3.6 plus, MSVC 1930, then setsCXX_STANDARD 11andC_STANDARD 11with fallback to 99. Many tests already usecxx_std_17.c_loaderandplugin_extensionrequire 17 foroptionalandfilesystem. Core and tests drift.AGENTS.mdclaims C23 and C++23 default with C17 fallback. CMake says C11 and C++11. Docs must state one truth..github/workflows/clang-format.yml:18pinsclang-format-version: 12. Team decision: use latest clang-format..clang-format:1-110uses LLVM base,UseTab: Always,ColumnLimit: 0,UseCRLF: true. CRLF plus tabs cause noisy diffs on Linux and macOS. Team decision: use LF.cmake/ClangDevTools.cmake:19-37leavesclang-tidycommented out. Onlyclang-formattarget exists. No tidy CI.cmake/FindNodeJS.cmakekeepsvs2017branches and Node 12 logic.cmake/FindLibClang.cmake,FindLibTCC.cmake,FindLibFFI.cmakepredate current LLVM and runtime releases. No clear minimum host compiler table per OS.cmake/SecurityFlags.cmake,cmake/Warnings.cmakelack unified-Wall -Wextra -Werror -fsanitize=address,undefinedstory withCompileOptions.cmakesanitizer blocks.
Tasks
- Decide baseline and record it: proposal is C17 minimum plus C++17 minimum, allow C23 and C++23 where toolchain supports it. Update
cmake/CompileOptions.cmakeand allcxx_std_17uses to one variable. Remove C99 fallback or state where it still applies. - Use latest
clang-formatin workflow, not pinned old major. Set.clang-formatto LF only (UseCRLF: false), review tab policy, set saneColumnLimit, keep LLVM base only if team agrees. Run format once as separate PR to keep diff reviewable. - Enable
clang-tidyincmake/ClangDevTools.cmakewith small initial checks:bugprone-*,clang-analyzer-*,modernize-use-nullptr,readability-braces-around-statements. Run warnings-only first, then enforce in CI per Tier 1. - Update Find modules:
FindNodeJS,FindLibClang,FindLibTCC,FindDotNET,FindWasmtime,FindJulia. Drop EOL branches such asvs2017and Node 12 paths. Add version floor checks with clear fatal messages. - Publish host toolchain table per Rosetta-3 tiers: Tier 1 Linux x86-64 GCC and Clang floors, Tier 2 macOS ARM64 AppleClang floor plus Windows MSVC floor. Include CMake, Ninja, Python host deps.
- Sync docs: update Rosetta-1 reference, Rosetta-4 build options, Rosetta-7 contributing flow, root
AGENTS.mdbuild flags. State sanitizer flow: ASan plus UBSan, TSan, MSan, memcheck. - Verify with clean builds: Linux GCC, Linux Clang, plus one Tier 2 host where possible. Run
ctest,clang-formatcheck, tidy run.
Non-goals
- No loader runtime upgrades here. Track per-loader upgrades separately.
- No full
cpp_loaderhere. Track under Rosetta-3 Tier 3. - No CMake minimum version bump unless required for new features. Propose separately if needed.
Acceptance
- One baseline table merged and linked from contributing guide.
- Format check green on latest clang-format with LF only, zero CRLF.
- Tidy runs in CI warnings-only with zero new high-severity hits.
- Find modules fail fast with clear message on unsupported hosts.
- Tier 1 build plus tests green on GCC and Clang.
- Dominant language
- C
- Stars
- 1.8k
- Forks
- 266
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 14
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from metacall/core
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
metacall/core#964 · 1 comment ·
Maintainers usually reply within 1 day
-
pre-push hook empties VERSION when the clone has no tagsPossibly taken @vedant21-oss claimed this 18 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
metacall/core#939 · 3 comments ·
Maintainers usually reply within 1 day
-
TOCTOU race condition vulnerability!Possibly taken @akshatchitransh claimed this 1 day ago. Openbug
Difficulty 4/5 3-5 days Newbie friendliness 35/100
metacall/core#961 · 2 comments ·
Maintainers usually reply within 1 day
-
bug
Difficulty 3/5 Half a day Newbie friendliness 70/100
Maintainers usually reply within 1 day
-
Go Port Race Conditions on MacOSPossibly taken A pull request linked to this issue is open or already merged. Openbug
Difficulty 4/5 3-5 days Newbie friendliness 35/100
metacall/core#942 · 3 comments ·
Maintainers usually reply within 1 day
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
`table_create()` crashes when an `hccalloc()` for the option table failsPossibly taken @marinelay claimed this today. Opentype: bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug severity: low
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
AlessandroSangiuliano/Uros#950 ·
-
vim.text.indent(): expandtab fails on single-tab blank lines and CRLF blank lines reset old_indent to 0Possibly taken A pull request linked to this issue is open or already merged. Openlua
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Maintainers usually reply within 1 day