Skip to content

Latest commit

 

History

History
57 lines (42 loc) · 1.93 KB

CommonModuleMissingAPI.md

File metadata and controls

57 lines (42 loc) · 1.93 KB

Common module should have a programming interface (CommonModuleMissingAPI)

Type Scope Severity Activated
by default
Minutes
to fix
Tags
Code smell BSL Major Yes 1 brainoverload
suspicious

Description

A common module must have at least one export method and region "Public" or "Internal".

Examples

Incorrect

// Start module
Procedure Test(A)
    A = A + 1;
EndProcedure
// End module

Correct

// Start module
#Region Internal
Procedure Test(A) Export
    A = A + 1;
EndProcedure
#EndRegion
// End module

Sources

Source: Standard: Module structure

Snippets

Diagnostic ignorance in code

// BSLLS:CommonModuleMissingAPI-off
// BSLLS:CommonModuleMissingAPI-on

Parameter for config

"CommonModuleMissingAPI": false