diff options
| author | Enji Cooper <ngie@FreeBSD.org> | 2026-08-09 22:45:11 +0000 |
|---|---|---|
| committer | Enji Cooper <ngie@FreeBSD.org> | 2026-08-09 22:56:50 +0000 |
| commit | fd809148cafd880aedb4e9db101742f7b1de4317 (patch) | |
| tree | 5ab93f1f637545b55bcbd6836da6b87a5ff11ed3 /share/man/man9 | |
| parent | af3f2dd124f07342c273dc017bc5e73639e446a5 (diff) | |
pmc(8): resolve -Wshadow issues
- Prefix all structs with the struct keyword to avoid collisions between
the types and variables with the same "name".
- Use `_` suffixed variables in initializers to distinguish input
parameters from public members [1].
Resolve some trailing whitespace issues while here.
NOTE: this doesn't resolve the -pedantic issue reported by g++ with
`pmchdr_cpuidinfo::cpuid` about the field being a flexible array in an
otherwise empty struct.
1. I generally do this the other way around, i.e., suffix private/protected
members with `_`, but these are public members in structs and I don't want
to introduce a lot of churn in calling code.
Reported by: g++14 with FreeBSD CI (powerpc64 tinderbox)
Fixes: ce6ab51f ("pmc: enable the new pmc commands")
Diffstat (limited to 'share/man/man9')
0 files changed, 0 insertions, 0 deletions
