Inappropriate Source Code Style or Formatting

Incomplete Class
Structure: Simple
Description

The source code does not follow desired style or formatting for indentation, white space, comments, etc.

Demonstrative Examples 1

ID : DX-215

The usage of symbolic names instead of hard-coded constants is preferred.
The following is an example of using a hard-coded constant instead of a symbolic name.

Code Example:

Bad
C
c
If the buffer value needs to be changed, then it has to be altered in more than one place. If the developer forgets or does not find all occurrences, in this example it could lead to a buffer overflow.

Code Example:

Good
C
c
In this example the developer will only need to change one value and all references to the buffer size are updated, as a symbolic name is used instead of a hard-coded constant.