Skip to content

perf: protected interface destructors; bump numerical-toolbox to 63c9b91 - #30

Merged
gabrielfrasantos merged 2 commits into
mainfrom
claude/peaceful-hawking-7sef6o
Oct 24, 2026
Merged

gabrielfrasantos merged 2 commits into
mainfrom
claude/peaceful-hawking-7sef6o

Conversation

@gabrielfrasantos

Copy link
Copy Markdown
Contributor

Two follow-ups to the wheeled-robot roadmap work.

build: bump numerical-toolbox adfc10d → 63c9b91

perf: make interface destructors protected and non-virtual

  • Same change as perf: make interface destructors protected and non-virtual numerical-toolbox-cpp#361, applied to dynamics::NewtonEulerBody and dynamics::EulerLagrangeDynamics.
  • Reason: a virtual destructor puts a deleting destructor in every implementation's vtable, which links operator delete (and malloc/free) into heap-free firmware.
  • Nothing in the library, its tests or the simulator destroys an object through these interfaces. Deleting through an interface pointer is now a compile error.
  • The rule is updated in AGENTS.md, CLAUDE.md, .github/copilot-instructions.md, .github/instructions/robotics-cpp.instructions.md and .github/agents/reviewer.agent.md.
  • The five roadmap specs that declare new interfaces follow the new rule: JacobianProvider, InverseDynamicsModel, InertialRegressor, PathGeometry and JointLimits.

Local check

  • cmake --preset host-single-Debug && cmake --build … && ctest: build clean with warnings as errors, 2/2 test suites pass.
  • The simulator needs Qt, so it was not built locally. It includes only upstream math headers, and of those only Math.hpp changed in this range, by additions only.

Generated by Claude Code

Picks up NT53–NT65 (now shipped upstream), the NT66 SE(2) spec, and
upstream's protected, non-virtual interface destructors. The roadmap
note about the pin is updated to match.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Mmp77ieEy16GxJL8KsLsVx
Same change as numerical-toolbox-cpp#361. NewtonEulerBody and
EulerLagrangeDynamics declared `virtual ~I() = default`. That puts a
deleting destructor in every implementation's vtable, which links
operator delete, and with it malloc/free, into heap-free firmware.
Nothing in the library, the tests or the simulator destroys an object
through these interfaces, so both now have a protected, non-virtual
destructor. Deleting through an interface pointer becomes a compile
error.

The rule is updated in AGENTS.md, CLAUDE.md,
.github/copilot-instructions.md, the C++ instructions and the reviewer
agent. The roadmap specs that declare new interfaces (JacobianProvider,
InverseDynamicsModel, InertialRegressor, PathGeometry, JointLimits)
follow it too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Mmp77ieEy16GxJL8KsLsVx
@github-actions

Copy link
Copy Markdown

✅⚠️MegaLinter analysis: Success with warnings

Descriptor Linter Files Fixed Errors Max errors Warnings Elapsed time
✅ ACTION actionlint 7 0 0 0.7s
✅ CPP clang-format 35 0 0 0 0.72s
✅ CPP cppcheck 35 0 0 1.21s
✅ DOCKERFILE hadolint 1 0 0 0.68s
✅ JSON jsonlint 8 0 0 0.11s
✅ JSON prettier 8 2 0 0 0.45s
⚠️ MARKDOWN markdownlint 149 0 1 0 2.35s
✅ MARKDOWN markdown-table-formatter 149 0 0 0 0.23s
⚠️ SPELL lychee 183 1 0 2.37s
✅ YAML prettier 12 0 0 0 0.54s
✅ YAML yamllint 12 0 0 0.69s

Detailed Issues

⚠️ SPELL / lychee - 1 error
📝 Summary
---------------------
🔍 Total..........134
🔗 Unique..........68
✅ Successful.....123
⏳ Timeouts.........0
🔀 Redirected.......5
👻 Excluded.........9
❓ Unknown..........0
🚫 Errors...........1
⛔ Unsupported......1

Errors in .github/workflows/static-analysis.yml
[403] https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$ (at 37:21) | Rejected status code: 403 Forbidden

Hint: Followed 5 redirects. You might want to consider replacing redirecting URLs with the resolved URLs. Use verbose mode (`-v`/`-vv`) to see redirection details.
Hint: You can configure accepted/rejected response codes with `-a` or `--accept`
⚠️ MARKDOWN / markdownlint - 1 error
.github/instructions/robotics-cpp.instructions.md:59:401 error MD013/line-length Line length [Expected: 400; Actual: 615]

Notices

⚠️ Your configuration references items that have been removed from MegaLinter and are ignored: REPOSITORY_GITLEAKS, REPOSITORY_KICS. See Removed linters to find their replacements.

See detailed reports in MegaLinter artifacts

Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining FLAVOR_SUGGESTIONS: false)

  • Documentation: Custom Flavors
  • Command: npx mega-linter-runner@10.1.0 --custom-flavor-setup --custom-flavor-linters ACTION_ACTIONLINT,CPP_CPPCHECK,CPP_CLANG_FORMAT,DOCKERFILE_HADOLINT,JSON_JSONLINT,JSON_PRETTIER,MARKDOWN_MARKDOWNLINT,MARKDOWN_MARKDOWN_TABLE_FORMATTER,SPELL_LYCHEE,YAML_PRETTIER,YAML_YAMLLINT

MegaLinter is provided by OX Security
Show us your support by starring ⭐ the repository

@sonarqubecloud

Copy link
Copy Markdown

@gabrielfrasantos
gabrielfrasantos merged commit ee4594e into main Oct 24, 2026
9 checks passed
@gabrielfrasantos
gabrielfrasantos deleted the claude/peaceful-hawking-7sef6o branch October 24, 2026 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants