Navigation Menu

Skip to content

Commit

Permalink
doc coding-style: add about naming rule for member variable
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Mar 15, 2012
1 parent 96e7fb4 commit 65586d6
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions doc/source/developer/coding_style.rst
Expand Up @@ -170,3 +170,30 @@ TODO: ちゃんと考える。
class HaMroonga: public handler
{
}

メンバー変数名
^^^^^^^^^^^^^^

メンバー変数名は ``snail_case`` とし、末尾にアンダースコア( ``_`` )を付ける。

よい例:

class MyClass
{
char *my_name_;
}
悪い例( ``UpperCamelCase`` である):

class MyClass
{
char *MyName_;
}
悪い例(末尾にアンダースコアがない):

class MyClass
{
char *my_name;
}

0 comments on commit 65586d6

Please sign in to comment.