Update CmpDriver to report missing commands.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62728 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/utils/CmpDriver b/utils/CmpDriver
index cc4caad..5420984 100755
--- a/utils/CmpDriver
+++ b/utils/CmpDriver
@@ -152,7 +152,16 @@
differ = True
# Compare commands.
- for i,(a,b) in enumerate(zip(infoA.commands, infoB.commands)):
+ for i,(a,b) in enumerate(map(None, infoA.commands, infoB.commands)):
+ if a is None:
+ print 'A MISSING:',' '.join(b)
+ differ = True
+ continue
+ elif b is None:
+ print 'B MISSING:',' '.join(a)
+ differ = True
+ continue
+
diff = DriverZipperDiff(a,b)
diffs = list(diff.getDiffs())
if diffs:
@@ -169,7 +178,7 @@
print 'mismatch: A: %s' % aElt
print ' B: %s' % bElt
differ = True
-
+
# Compare result codes.
if infoA.exitCode != infoB.exitCode:
print '-- EXIT CODES DIFFER -'