From 6c2a5ab4aa0c1cf369e5f86a8469c9e6055c21ec Mon Sep 17 00:00:00 2001 From: Patrick Gartung Date: Wed, 1 Oct 2014 11:19:42 -0500 Subject: [PATCH] guard against blank lines in db.tct --- Utilities/StaticAnalyzers/scripts/data-class-funcs.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Utilities/StaticAnalyzers/scripts/data-class-funcs.py b/Utilities/StaticAnalyzers/scripts/data-class-funcs.py index 31b3241c73573..a7cfa9e451303 100755 --- a/Utilities/StaticAnalyzers/scripts/data-class-funcs.py +++ b/Utilities/StaticAnalyzers/scripts/data-class-funcs.py @@ -1,6 +1,7 @@ #! /usr/bin/env python import re datacl = re.compile("^class ") +bfunc = re.compile("^function ") mbcl = re.compile("(base|data) class") farg = re.compile("(.*)\(\w+\)") nsep = re.compile("\:\:") @@ -65,6 +66,7 @@ f = open('db.txt') for line in f : + if not bfunc.search(line) : continue fields = line.split("'") if fields[2] == ' calls function ' : G.add_edge(fields[1],fields[3],kind=' calls function ')