more small *.py cleanups (#1329)

* added CLion project folder to .gitignore

* adjusted project name in CMakeLists.txt

* avoid warning when compiling "Debug" with Visual Studio via CMake

There was a GCC-style compiler flag in the common flags in compileroptions.cmake which caused the following warning:
cl : Command line warning D9002 : ignoring unknown option '-O0'

* compileroptions.cmake: restored original formatting

* daca2.py: added missing import

* misra.py: removed unnecessary escaping from regular expression
This commit is contained in:
Oliver Stöneberg 2018-08-06 22:07:58 +02:00 committed by Daniel Marjamäki
parent 750ba1a4c1
commit bb27bc280a
2 changed files with 2 additions and 1 deletions

View File

@ -663,7 +663,7 @@ def misra_5_3(data):
def misra_5_4(data): def misra_5_4(data):
macro = {} macro = {}
compile_name = re.compile(r'#define ([a-zA-Z0-9_]+)') compile_name = re.compile(r'#define ([a-zA-Z0-9_]+)')
compile_param = re.compile(r'#define ([a-zA-Z0-9_]+)[\(]([a-zA-Z0-9_, ]+)[\)]') compile_param = re.compile(r'#define ([a-zA-Z0-9_]+)[(]([a-zA-Z0-9_, ]+)[)]')
for dir in data.directives: for dir in data.directives:
res1 = compile_name.match(dir.str) res1 = compile_name.match(dir.str)
if res1: if res1:

View File

@ -7,6 +7,7 @@
# 5. Run the daca2 script: python daca2.py FOLDER # 5. Run the daca2 script: python daca2.py FOLDER
import argparse import argparse
import logging
import subprocess import subprocess
import sys import sys
import shutil import shutil