for comment, define in block_tmp:
block.append((" ".join(re.findall(r"^\s*\*?\s*(.*?)\s*?$", comment, re.MULTILINE)), define))
block += re.findall(r"/{3}<?\s*(.*)\s*#define\s+(.*)\s*?$", text, re.MULTILINE)
+ block += [(comment, define) for define, comment in re.findall(r"#define\s*(.*?)\s*/{3}<\s*(.*?)\s*?$", text, re.MULTILINE)]
return block
def loadModuleInfos(path):
moduleInfos[moduleName] = []
for element in getDefinitionBlocks(open(definition[1] + "/" + definition[0], "r").read()):
moduleInfos[moduleName].append(element)
- return moduleInfos
\ No newline at end of file
+ return moduleInfos