naming convention of temp local variables

后端 未结 11 1134
我在风中等你
我在风中等你 2021-01-23 05:40

What is the standard way to name a temp variable in the local function? let me give you an illustration of what I am doing. I get a pointer to a structure, so I want store one o

11条回答
  •  温柔的废话
    2021-01-23 05:50

    If a more descriptive them can't be thought of, the convention we practice at work is to use the name "my[object]" in lieu of a better name. Above all, make it descriptive so that your code is easier to understand and maintain. Self-documenting code is another benefit of doing this.

提交回复
热议问题