[webkit-dev] Naming convention for static member variables

Simon Fraser simon.fraser at apple.com
Wed Feb 19 14:04:44 PST 2020


Thank you. I filed https://bugs.webkit.org/show_bug.cgi?id=207961 <https://bugs.webkit.org/show_bug.cgi?id=207961>

Simon

> On Feb 19, 2020, at 11:39 AM, Konstantin Tokarev <annulen at yandex.ru> wrote:
> 
> 
> 
> 19.02.2020, 22:31, "Simon Fraser" <simon.fraser at apple.com>:
>> class Foo {
>>   static bool thing.
>> };
>> 
>> What's the naming convention for static member variables like this? I've seen m_foo, which seems positively harmful. I've seen s_foo, which I like.
>> 
>> There are 165 instances of s_ that I can find in the project. There are 17 instances of static m_.
> 
> According to [1], convention is "s_". Apparently, it just lacks an enforcement in style checker.
> 
> [1] https://webkit.org/code-style-guidelines/#names-data-members
> 
> -- 
> Regards,
> Konstantin
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20200219/86fa4c57/attachment.htm>


More information about the webkit-dev mailing list