-
Notifications
You must be signed in to change notification settings - Fork 77
Expand file tree
/
Copy pathFunctionsDeclaredAtBlockScope.ql
More file actions
26 lines (23 loc) · 1.01 KB
/
FunctionsDeclaredAtBlockScope.ql
File metadata and controls
26 lines (23 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/**
* @id cpp/autosar/functions-declared-at-block-scope
* @name M3-1-2: Functions shall not be declared at block scope
* @description A function declared at block scope will refer to a member of the enclosing
* namespace, and so the declaration should be explicitly placed at the namespace
* level.
* @kind problem
* @precision very-high
* @problem.severity warning
* @tags external/autosar/id/m3-1-2
* correctness
* maintainability
* external/autosar/allocated-target/implementation
* external/autosar/enforcement/automated
* external/autosar/obligation/required
*/
import cpp
import codingstandards.cpp.autosar
import codingstandards.cpp.rules.functiondeclaredatblockscope.FunctionDeclaredAtBlockScope
module FunctionDeclaredAtBlockScopeConfig implements FunctionDeclaredAtBlockScopeConfigSig {
Query getQuery() { result = DeclarationsPackage::functionsDeclaredAtBlockScopeQuery() }
}
import FunctionDeclaredAtBlockScope<FunctionDeclaredAtBlockScopeConfig>