From c7ff82c2040f45eaad2eddea0e4461dddc972cd1 Mon Sep 17 00:00:00 2001 From: David Chisnall Date: Sun, 26 Dec 2010 20:12:30 +0000 Subject: Fix for PR8695. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@122564 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/AST/ASTContext.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/AST/ASTContext.cpp') diff --git a/lib/AST/ASTContext.cpp b/lib/AST/ASTContext.cpp index eb6a821783..b1fd16fb07 100644 --- a/lib/AST/ASTContext.cpp +++ b/lib/AST/ASTContext.cpp @@ -3785,7 +3785,10 @@ static void EncodeBitField(const ASTContext *Context, std::string& S, break; } S += llvm::utostr(RL.getFieldOffset(i)); - S += ObjCEncodingForPrimitiveKind(Context, T); + if (T->isEnumeralType()) + S += 'i'; + else + S += ObjCEncodingForPrimitiveKind(Context, T); } unsigned N = E->EvaluateAsInt(*Ctx).getZExtValue(); S += llvm::utostr(N); -- cgit v1.2.3-18-g5258