From 98c90acdfc9813ad8789974df1705e0a240194fd Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 25 Jul 2016 13:22:38 +0200 Subject: loplugins: more consistent naming of output files Change-Id: Ia26f697cb16078f235c94e4cff449a60c1bbd74e --- compilerplugins/clang/mergeclasses.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'compilerplugins/clang/mergeclasses.py') diff --git a/compilerplugins/clang/mergeclasses.py b/compilerplugins/clang/mergeclasses.py index 58a65c58c837..23a15f62af66 100755 --- a/compilerplugins/clang/mergeclasses.py +++ b/compilerplugins/clang/mergeclasses.py @@ -7,7 +7,7 @@ definitionSet = set() parentChildDict = {} definitionToFileDict = {} -with open("mergeclasses.log") as txt: +with open("loplugin.mergeclasses.log") as txt: for line in txt: if line.startswith("instantiated:\t"): @@ -54,6 +54,7 @@ def extractModuleName(clazz): idx = filename.find("/") return filename[:idx] +with open("loplugin.mergeclasses.report", "wt") as f: for clazz in sorted(definitionSet - instantiatedSet): # find uninstantiated classes without any subclasses if (not(clazz in parentChildDict)) or (len(parentChildDict[clazz]) != 1): @@ -70,5 +71,5 @@ for clazz in sorted(definitionSet - instantiatedSet): # exclude combinations that span modules because we often use those to make cross-module dependencies more manageable. if extractModuleName(clazz) != extractModuleName(otherclazz): continue - print "merge", clazz, "with", otherclazz + f.write( "merge" + clazz + "with" + otherclazz + "\n" ) -- cgit