diff options
| author | Ken Dyck <ken.dyck@onsemi.com> | 2010-01-11 17:06:35 +0000 |
|---|---|---|
| committer | Ken Dyck <ken.dyck@onsemi.com> | 2010-01-11 17:06:35 +0000 |
| commit | 40775003e64d52af725880f2afa0b615d0d9d4aa (patch) | |
| tree | 05a6efcf457cf46d383ecf4badf6489e50f71709 /clang/lib/Sema | |
| parent | 64d9f4055757b4d8d7d6090f603d514eec0fc6eb (diff) | |
| download | bcm5719-llvm-40775003e64d52af725880f2afa0b615d0d9d4aa.tar.gz bcm5719-llvm-40775003e64d52af725880f2afa0b615d0d9d4aa.zip | |
Roll out ASTContext::getTypeSizeInChars(), replacing instances of
"ASTContext::getTypeSize() / 8". Replace [u]int64_t variables with CharUnits
ones as appropriate.
Also rename RawType, fromRaw(), and getRaw() in CharUnits to QuantityType,
fromQuantity(), and getQuantity() for clarity.
llvm-svn: 93153
Diffstat (limited to 'clang/lib/Sema')
| -rw-r--r-- | clang/lib/Sema/SemaChecking.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp index 7bb456e66be..5f124e45722 100644 --- a/clang/lib/Sema/SemaChecking.cpp +++ b/clang/lib/Sema/SemaChecking.cpp @@ -14,6 +14,7 @@ #include "Sema.h" #include "clang/AST/ASTContext.h" +#include "clang/AST/CharUnits.h" #include "clang/AST/DeclObjC.h" #include "clang/AST/ExprCXX.h" #include "clang/AST/ExprObjC.h" @@ -318,7 +319,7 @@ bool Sema::SemaBuiltinAtomicOverloaded(CallExpr *TheCall) { // Determine the index of the size. unsigned SizeIndex; - switch (Context.getTypeSize(ValType)/8) { + switch (Context.getTypeSizeInChars(ValType).getQuantity()) { case 1: SizeIndex = 0; break; case 2: SizeIndex = 1; break; case 4: SizeIndex = 2; break; |

