From 3c10ddd46a91ab6e7cb1972269d069b4d590b2f0 Mon Sep 17 00:00:00 2001 From: Matt Pharr Date: Thu, 21 Jun 2012 14:40:24 -0700 Subject: [PATCH] Fix declaration of size_t. It should be an unsigned integer type. --- module.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module.cpp b/module.cpp index 97f6b003..e00be0cc 100644 --- a/module.cpp +++ b/module.cpp @@ -114,7 +114,7 @@ lDeclareSizeAndPtrIntTypes(SymbolTable *symbolTable) { symbolTable->AddType("ptrdiff_t", ptrIntType, SourcePos()); const Type *sizeType = (g->target.is32Bit || g->opt.force32BitAddressing) ? - AtomicType::VaryingInt32 : AtomicType::VaryingInt64; + AtomicType::VaryingUInt32 : AtomicType::VaryingUInt64; sizeType = sizeType->GetAsUnboundVariabilityType(); symbolTable->AddType("size_t", sizeType, SourcePos()); }