project-chip / connectedhomeip

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.
https://buildwithmatter.com
Apache License 2.0
7.34k stars 1.97k forks source link

Stop using the `a*` pattern for method input parameters #34541

Open hicklin opened 1 month ago

hicklin commented 1 month ago

Following this PR comment, this issue is to track the removal of the a* pattern for method input parameters.

bzbarsky-apple commented 1 month ago

I am fine with that if we also get rid of the "p" and "mp" prefixes....

What is the plan for the "m" and "s" prefixes for members?

That said, I should note that contrary to the PR comment cited above "a" prefixes are not "Hungarian style". Hungarian style is when the type is encoded into the name. This is encoding semantic/lifetime information, not the type.

hicklin commented 1 month ago

Is there a "standard" or at least "preferred" style guide for matter? So far I have been trying to mimic what I have seen elsewhere in the SDK. Sometimes I happen to choose the wrong example.

bzbarsky-apple commented 1 month ago

There is not. For new files, it's people doing whatever they want. For existing files, follow file style.