LinterCop

The LinterCop is a code linter for AL, comparable to widely used static analysis linters in other programming languages. It flags code quality issues, measures complexity, and promotes modern AL patterns. The code it flags is technically valid, but can be written in a cleaner, more maintainable or more idiomatic way.

Rules

IDTitleSeverityEnabledCode Fix
LC0003Do not use Object IDs as object referencesWarning
LC0007Maintainability Index metricHidden
LC0008Maintainability Index threshold exceededWarning
LC0009Cyclomatic Complexity metricInfo
LC0010Cyclomatic Complexity threshold exceededWarning
LC0019DataClassification redundancyWarning
LC0020ApplicationArea redundancyInfo
LC0028Use identifier syntax in event subscriber argumentsWarning
LC0031Use ReadIsolation instead of LockTableInfo
LC0033App manifest runtime is behind target versionWarning
LC0040Explicitly set RunTriggerInfo
LC0043Use SecretText for sensitive textWarning
LC0048Use Error with ErrorInfo or Label instead of TextWarning
LC0052Internal procedure not referencedWarning
LC0053Internal procedure only used in current objectWarning
LC0054Interface object name guideHidden
LC0063API page canonical field name guideInfo
LC0081Use IsEmpty method instead of CountWarning
LC0082Use Query or Find with Next instead of CountInfo
LC0083Use new Date/Time/DateTime methods for extracting partsInfo
LC0086Page style should not use string literalWarning
LC0088Prefer Enum over Option typeInfo
LC0089Cognitive Complexity metricHidden
LC0090Cognitive Complexity threshold exceededWarning
LC0091Translatable text should be translatedWarning
LC0092Name does not match naming conventionWarning
LC0094AllowInCustomizations redundancyWarning
LC0095Parameter is not referencedWarning
LC0096Unnecessary record parameter in method callWarning