diff options
Diffstat (limited to 'clang/utils/ABITest/ABITestGen.py')
-rwxr-xr-x | clang/utils/ABITest/ABITestGen.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/utils/ABITest/ABITestGen.py b/clang/utils/ABITest/ABITestGen.py index 5b9756b5450..bdf0be4f1d9 100755 --- a/clang/utils/ABITest/ABITestGen.py +++ b/clang/utils/ABITest/ABITestGen.py @@ -263,7 +263,10 @@ class TypePrinter: 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,) |