diff options
author | Ken Dyck <ken.dyck@onsemi.com> | 2011-01-14 02:01:36 +0000 |
---|---|---|
committer | Ken Dyck <ken.dyck@onsemi.com> | 2011-01-14 02:01:36 +0000 |
commit | 4e26caa0365347eb63d483df29cdf86ca084510c (patch) | |
tree | 9dd0db255434778b58e7ca7d3a975f8577f24258 /lib/AST/ExprConstant.cpp | |
parent | 852f65beb12a7a735b17b60856e701be14d627d4 (diff) |
Replace a literal '8' with getCharWidth().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123421 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/ExprConstant.cpp')
-rw-r--r-- | lib/AST/ExprConstant.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/AST/ExprConstant.cpp b/lib/AST/ExprConstant.cpp index 8761aa3f94..57ceb3f481 100644 --- a/lib/AST/ExprConstant.cpp +++ b/lib/AST/ExprConstant.cpp @@ -404,7 +404,8 @@ bool LValueExprEvaluator::VisitMemberExpr(MemberExpr *E) { break; } - Result.Offset += CharUnits::fromQuantity(RL.getFieldOffset(i) / 8); + Result.Offset += + CharUnits::fromQuantity(RL.getFieldOffset(i) / Info.Ctx.getCharWidth()); return true; } |