Convention: Variable Name Length Check

User Description

Coding style is a set of rules or guidelines applied when writing source code. Following a specified coding style helps:

  • To read and understand the source code

  • To avoid and find programming issues

  • To maintain the source code

For readability reasons, there are suggestions for variable names and length. The length of variables can be verified against a user-defined limit.

Convention Verification Rule

The length of a variable name is compared with a length threshold.

Example

iMyVariable                                 // length 11 --> OK
iSpecialAndVeryLongAndHardToReadVariable    // length 20 --> Not OK