MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / misra_7_3

Method misra_7_3

addons/misra.py:2060–2066  ·  view source on GitHub ↗
(self, rawTokens)

Source from the content-addressed store, hash-verified

2058 self.reportError(token, 7, 2)
2059
2060 def misra_7_3(self, rawTokens):
2061 # Match decimal digits, hex digits, decimal point, and e/E p/P floating
2062 # point constant exponent separators.
2063 compiled = re.compile(r'^(0[xX])?[0-9a-fA-FpP.]+[Uu]*l+[Uu]*$')
2064 for tok in rawTokens:
2065 if compiled.match(tok.str):
2066 self.reportError(tok, 7, 3)
2067
2068 def misra_7_4(self, data):
2069 # A string literal shall not be assigned to an object unless the object's type

Callers

nothing calls this directly

Calls 3

reportErrorMethod · 0.95
compileMethod · 0.80
matchMethod · 0.45

Tested by

no test coverage detected