word size fixups

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@34468 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2012-01-09 08:28:27 +00:00
parent f339497d46
commit 3fcd9f7d04
15 changed files with 63 additions and 36 deletions

View file

@ -3789,8 +3789,8 @@ appendString(NSMutableData *m, NSUInteger offset, NSUInteger fold,
}
if (offset > fold)
{
NSLog(@"Name '%@' too long for folding at %lu in header",
n, (unsigned long)fold);
NSLog(@"Name '%@' too long for folding at %"PRIuPTR" in header",
n, fold);
}
offset = appendBytes(md, offset, fold, ":", 1);

View file

@ -4696,8 +4696,13 @@ static void indentation(unsigned level, NSMutableString *str)
INDENT(indent);
if (strchr("cCsSiIlL", *t) != 0)
{
long i = [self longValue];
int64_t i = [self longLongValue];
if ((i & 0xffffffff) != i)
{
[NSException raise: NSInternalInconsistencyException
format: @"Can't encode %"PRId64" as i4"];
}
if ((i == 0 || i == 1) && (*t == 'c' || *t == 'C'))
{
if (i == 0)
@ -4711,7 +4716,7 @@ static void indentation(unsigned level, NSMutableString *str)
}
else
{
[str appendFormat: @"<i4>%ld</i4>", i];
[str appendFormat: @"<i4>%"PRId32"</i4>", (int32_t)i];
}
}
else