[cfe-commits] r63296 - /cfe/trunk/utils/ABITest/ABITestGen.py
Daniel Dunbar
daniel at zuster.org
Thu Jan 29 00:48:06 PST 2009
Author: ddunbar
Date: Thu Jan 29 02:48:06 2009
New Revision: 63296
URL: http://llvm.org/viewvc/llvm-project?rev=63296&view=rev
Log:
ABITest: Fix access to array test values.
Modified:
cfe/trunk/utils/ABITest/ABITestGen.py
Modified: cfe/trunk/utils/ABITest/ABITestGen.py
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/utils/ABITest/ABITestGen.py?rev=63296&r1=63295&r2=63296&view=diff
==============================================================================
--- cfe/trunk/utils/ABITest/ABITestGen.py (original)
+++ cfe/trunk/utils/ABITest/ABITestGen.py Thu Jan 29 02:48:06 2009
@@ -263,7 +263,10 @@
for i in range(t.numElements):
# Access in this fashion as a hackish way to portably
# access vectors.
- self.printValueOfType(prefix, '((%s*) &%s)[%d]'%(t.elementType,name,i), t.elementType, output=output,indent=indent)
+ if t.isVector:
+ self.printValueOfType(prefix, '((%s*) &%s)[%d]'%(t.elementType,name,i), t.elementType, output=output,indent=indent)
+ else:
+ self.printValueOfType(prefix, '%s[%d]'%(name,i), t.elementType, output=output,indent=indent)
else:
raise NotImplementedError,'Cannot print value of type: "%s"'%(t,)
More information about the cfe-commits
mailing list