You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Considering that template parameters of a class or struct cannot be accessed outside of it,
that accessors for template parameters are therefore useful, that these accessors cannot bear the same name as the template parameters (14.6.1, paragraph 6),
considering that a similar issue exists with private member variables, that we resolve it (following the Google C++ styleguide) by appending an underscore to the name of such variables,
considering that the other reasonable alternative, CamelCase prefixed by the letter k, used for compile-time constants of global or class scope, would hamper readability,
considering that underscores postfixing every template parameter would further impede readability of already abstruse template metaprogramming,
for these reasons,
the following naming convention shall be implemented for template parameters:
NonExportedTypeTemplateParameter;
non_exported_non_type_template_parameter;
ExportedTypeTemplateParameter_,
exported by using ExportedTypeTemplateParameter = ExportedTypeTemplateParameter_;
exported_non_type_template_parameter_, exported by static T const exported_non_type_template_parameter = exported_non_type_template_parameter_;.
The text was updated successfully, but these errors were encountered:
Considering that template parameters of a class or struct cannot be accessed outside of it,
that accessors for template parameters are therefore useful, that these accessors cannot bear the same name as the template parameters (14.6.1, paragraph 6),
considering that a similar issue exists with private member variables, that we resolve it (following the Google C++ styleguide) by appending an underscore to the name of such variables,
considering that the other reasonable alternative, CamelCase prefixed by the letter k, used for compile-time constants of global or class scope, would hamper readability,
considering that underscores postfixing every template parameter would further impede readability of already abstruse template metaprogramming,
for these reasons,
the following naming convention shall be implemented for template parameters:
NonExportedTypeTemplateParameter
;non_exported_non_type_template_parameter
;ExportedTypeTemplateParameter_
,exported by
using ExportedTypeTemplateParameter = ExportedTypeTemplateParameter_
;exported_non_type_template_parameter_
, exported bystatic T const exported_non_type_template_parameter = exported_non_type_template_parameter_;
.The text was updated successfully, but these errors were encountered: