10.1 Purpose. The purpose of this appendix is to specify language independent
requirements for software coding standards. The requirements specified in this appendix are a mandatory part of this standard.
10.2 Applicability. This appendix applies to all deliverable source code developed under the contract.
10.3 Rules and Conventions. The following subparagraphs define the requirements for rules and convention applicable to software coding standards. The contractor shall implement software coding standards that comply with these requirements.
10.3.1 Presentation style. The coding standards shall describe the rules and conventions for the format of the source code which may include paper listings, listings stored on electronic media, or both. The rules and conventions for presentation style shall include standards for:
a. Indentation and spacing
b. The use of capitalization
c. Uniform presentation of information throughout the source code (e.g.,the grouping together of all data declarations)
d. Use of headers
e. Layout of source code listings
f. Conditions under which comments are provided and the format to be used
g. Size of code aggregates (e.g. on the average 100
or at most 200 executable, non-expandable statements).
10.3.2 Naming. The coding standards shall describe the rules and conventions governing the selection of identifiers used in the source code listings (e.g., identifiers for CSUs, variables, parameters, packages, procedures, subunits, and other aggregates of code.) Restrictions on the use of reserve words and keywords shall be identified.
10.3.3 Restrictions on the Implementation language. The coding standards shall include a description of any restrictions imposed on the use of constructs and features of the implementation language due to project or machine-dependent characteristics. Machine-dependent characteristics may include input/output features, word length-dependent features, use of floating point arithmetic, etc. Project characteristics may include, but are not limited to, safety or security considerations in the operational environment.
10.3.4 Use of language constructs and features. The coding standards shall address the allowed use of constructs and features of the implementation language. For example, when Ada is the implementation language, the coding standards shall address such aspects as the use of exception handling, goto and abort statements, and unchecked conversion.
10.3.5 Complexity. The coding standards shall describe controls and restrictions on the complexity of code aggregates.