Add const to char* parameters that are not mutated#137
Merged
olofhagsand merged 1 commit intoclicon:masterfrom May 7, 2026
Merged
Add const to char* parameters that are not mutated#137olofhagsand merged 1 commit intoclicon:masterfrom
const to char* parameters that are not mutated#137olofhagsand merged 1 commit intoclicon:masterfrom
Conversation
Marked read-only string parameters as const in the public API: - expand_cb typedef: name parameter - clispec_parse_str: treename parameter - clispec_parse_file: name and treename parameters - cligen_parseerror: error string parameter Updated implementations and example callbacks to match. Signed-off-by: Ted Lyngmo <ted@lyncon.se>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #137 +/- ##
=======================================
Coverage 53.29% 53.30%
=======================================
Files 23 23
Lines 8038 8039 +1
Branches 1870 1870
=======================================
+ Hits 4284 4285 +1
Misses 2701 2701
Partials 1053 1053
... and 1 file with indirect coverage changes Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Marked read-only string parameters as const in the public API:
expand_cbtypedef:nameparameterclispec_parse_str:treenameparameterclispec_parse_file:nameandtreenameparameterscligen_parseerror: error string parameter (s)Updated implementations and example callbacks to match.