(sources)
| 27 | |
| 28 | |
| 29 | def inlineSourceFunctions(sources): |
| 30 | |
| 31 | # TODO: Tidy with clang first? |
| 32 | |
| 33 | for name in sources.keys(): |
| 34 | source = sources[name] |
| 35 | |
| 36 | if name == "Exceptions": |
| 37 | for i, line in enumerate(source): |
| 38 | if line.strip().startswith("void ") and line.strip().endswith(")"): |
| 39 | sources[name][i] = "inline " + line |
| 40 | |
| 41 | if name == "FileTypes": |
| 42 | for i, line in enumerate(source): |
| 43 | if line.strip().startswith("Type ") and line.strip().endswith(")"): |
| 44 | sources[name][i] = "inline " + line |
| 45 | |
| 46 | else: |
| 47 | for i, line in enumerate(source): |
| 48 | if name + "::" in line and not line.startswith(" ") and not line.strip().endswith(";"): |
| 49 | sources[name][i] = "inline " + line |
| 50 | |
| 51 | elif line.startswith("std::shared_ptr<BuiltInReader> BuiltIn()"): |
| 52 | sources[name][i] = "inline " + line |
| 53 | |
| 54 | |
| 55 | return sources |
| 56 | |
| 57 | |
| 58 | def stripComments(lines): |
no outgoing calls
no test coverage detected