@@ -45,7 +45,7 @@ WarningsAsErrors: >
4545 modernize-use-nullptr,
4646 modernize-use-override,
4747 performance-move-const-arg,
48- # readability-identifier-naming, # temporarily disabled during rename migration
48+ readability-identifier-naming,
4949
5050HeaderFilterRegex : ' .*'
5151
@@ -98,6 +98,49 @@ CheckOptions:
9898 value : CamelCase
9999 - key : readability-identifier-naming.TemplateParameterCase
100100 value : CamelCase
101+ # const/constexpr LOCALS follow lower_case (house style); the k-prefixed
102+ # Constant policy above applies to file-scope/global constants only.
103+ - key : readability-identifier-naming.LocalConstantCase
104+ value : lower_case
105+ - key : readability-identifier-naming.LocalConstantPrefix
106+ value : ' '
107+ - key : readability-identifier-naming.LocalVariableCase
108+ value : lower_case
109+ # `PJ` is the documented flat project namespace; `Ui` is uic-generated.
110+ - key : readability-identifier-naming.NamespaceIgnoredRegexp
111+ value : ' ^(PJ|Ui)$'
112+ # extern "C" C-ABI plugin contract: PJ_* structs/enums/enum-constants/entry
113+ # points and pj_* exported globals are the plugin binary ABI — recasing them
114+ # breaks every compiled plugin. Also exempt Google Benchmark BM_ functions and
115+ # the std::visit `overloaded` idiom.
116+ - key : readability-identifier-naming.FunctionIgnoredRegexp
117+ value : ' (BM_|PJ_|pj_).*'
118+ - key : readability-identifier-naming.StructIgnoredRegexp
119+ value : ' (overloaded|PJ_.*)'
120+ - key : readability-identifier-naming.EnumIgnoredRegexp
121+ value : ' PJ_.*'
122+ - key : readability-identifier-naming.EnumConstantIgnoredRegexp
123+ value : ' PJ_.*'
124+ - key : readability-identifier-naming.GlobalConstantIgnoredRegexp
125+ value : ' pj_.*'
126+ # Canonical schema and STL-/plugin-facing API are grandfathered: the ROS/OpenCV
127+ # CameraInfo/DepthImage intrinsics (single-capital D/K/R/P) are a wire-format
128+ # field contract; `has_value`/`value_or`/`error_or` are the std::expected drop-in
129+ # interface; and `load_config`/`save_config`/`trampoline_*` are plugin-author or
130+ # C-ABI-bridge methods that every compiled plugin links by name. Recasing any of
131+ # these breaks wire compat, STL-shaped generic code, or the plugin ABI. (Revisit
132+ # the snake_case plugin virtuals in a future coordinated 1.0.0.)
133+ - key : readability-identifier-naming.PublicMemberIgnoredRegexp
134+ value : ' ([A-Z]|fetchMessageData)'
135+ - key : readability-identifier-naming.MethodIgnoredRegexp
136+ value : ' (has_value|value_or|error_or|load_config|save_config|ui_content|widget_data|trampoline_.*)'
137+ - key : readability-identifier-naming.TypeAliasIgnoredRegexp
138+ value : ' json'
139+ # A trailing underscore on a *parameter* is the idiomatic shadow-avoidance form
140+ # (e.g. `PayloadView(Span bytes_) : bytes(bytes_)` where `bytes` is a member);
141+ # stripping it reintroduces a -Wshadow error. Exempt trailing-underscore params.
142+ - key : readability-identifier-naming.ParameterIgnoredRegexp
143+ value : ' .*_'
101144
102145 # --- Function size limits ---
103146 - key : readability-function-size.LineThreshold
0 commit comments