mirror of
https://github.com/gnustep/libs-gdl2.git
synced 2025-02-16 00:11:15 +00:00
* EOControl/EOCheapArray.m
* EOControl/EODebug.m * EOControl/EODetailDataSource.m * EOControl/EOEditingContext.m * EOControl/EOFaultHandler.m * EOControl/EOFault.m * EOControl/EOGenericRecord.m * EOControl/EOKeyComparisonQualifier.m * EOControl/EOKeyValueArchiver.m * EOControl/EOKeyValueCoding.m * EOControl/EOKeyValueQualifier.m * EOControl/EOMutableKnownKeyDictionary.m * EOControl/EOObjectStoreCoordinator.m * EOControl/EOPrivate.m * EOControl/EOQualifier.m * EOControl/EOSortOrdering.m fix format string warnings and do not directly access isa git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@37737 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
05e0d2b424
commit
a3abfc976a
17 changed files with 66 additions and 48 deletions
19
ChangeLog
19
ChangeLog
|
@ -1,3 +1,22 @@
|
|||
2014-03-09 Sebastian Reitenbach <sebastia@l00-bugdead-prods.de>
|
||||
* EOControl/EOCheapArray.m
|
||||
* EOControl/EODebug.m
|
||||
* EOControl/EODetailDataSource.m
|
||||
* EOControl/EOEditingContext.m
|
||||
* EOControl/EOFaultHandler.m
|
||||
* EOControl/EOFault.m
|
||||
* EOControl/EOGenericRecord.m
|
||||
* EOControl/EOKeyComparisonQualifier.m
|
||||
* EOControl/EOKeyValueArchiver.m
|
||||
* EOControl/EOKeyValueCoding.m
|
||||
* EOControl/EOKeyValueQualifier.m
|
||||
* EOControl/EOMutableKnownKeyDictionary.m
|
||||
* EOControl/EOObjectStoreCoordinator.m
|
||||
* EOControl/EOPrivate.m
|
||||
* EOControl/EOQualifier.m
|
||||
* EOControl/EOSortOrdering.m
|
||||
fix format string warnings and do not directly access isa
|
||||
|
||||
2014-03-08 Sebastian Reitenbach <sebastia@l00-bugdead-prods.de>
|
||||
* Apps/EOModelEditor/CodeGenerator.m
|
||||
* EOControl/EOClassDescription.m
|
||||
|
|
|
@ -147,7 +147,7 @@ RCS_ID("$Id$")
|
|||
- (id) autorelease
|
||||
{
|
||||
#ifdef DEBUG
|
||||
NSDebugFLog(@"autorelease EOCheapCopyArray %p. %@ [super retainCount]=%d",
|
||||
NSDebugFLog(@"autorelease EOCheapCopyArray %p. %@ [super retainCount]=%"PRIuPTR,
|
||||
(void*)self,GSCurrentThread(),[super retainCount]);
|
||||
#endif
|
||||
return [super autorelease];
|
||||
|
@ -156,7 +156,7 @@ RCS_ID("$Id$")
|
|||
- (oneway void) release
|
||||
{
|
||||
#ifdef DEBUG
|
||||
NSDebugFLog(@"Release EOCheapCopyArray %p. %@ [super retainCount]=%d",
|
||||
NSDebugFLog(@"Release EOCheapCopyArray %p. %@ [super retainCount]=%"PRIuPTR,
|
||||
(void*)self,GSCurrentThread(),[super retainCount]);
|
||||
#endif
|
||||
[super release];
|
||||
|
@ -175,7 +175,7 @@ RCS_ID("$Id$")
|
|||
- (id) retain
|
||||
{
|
||||
#ifdef DEBUG
|
||||
NSDebugFLog(@"retain EOCheapCopyArray %p. %@, [super retainCount]=%d",
|
||||
NSDebugFLog(@"retain EOCheapCopyArray %p. %@, [super retainCount]=%"PRIuPTR,
|
||||
(void*)self,GSCurrentThread(),[super retainCount]);
|
||||
#endif
|
||||
return [super retain];
|
||||
|
@ -255,7 +255,7 @@ RCS_ID("$Id$")
|
|||
- (void) dealloc
|
||||
{
|
||||
#ifdef DEBUG
|
||||
NSDebugFLog(@"Deallocate EOCheapCopyMutableArray %p zone=%p _contents_array=%p _count=%d _capacity=%d",
|
||||
NSDebugFLog(@"Deallocate EOCheapCopyMutableArray %p zone=%p _contents_array=%p _count=%"PRIuPTR" _capacity=%"PRIuPTR,
|
||||
self, [self zone], _contents_array, _count, _capacity);
|
||||
#endif
|
||||
if (_contents_array)
|
||||
|
@ -383,7 +383,7 @@ RCS_ID("$Id$")
|
|||
{
|
||||
[NSException raise: NSRangeException
|
||||
format:
|
||||
@"in insertObject:atIndex:, index %d is out of range",
|
||||
@"in insertObject:atIndex:, index %"PRIuPTR" is out of range",
|
||||
index];
|
||||
}
|
||||
|
||||
|
@ -443,7 +443,7 @@ RCS_ID("$Id$")
|
|||
if (index >= _count)
|
||||
{
|
||||
[NSException raise: NSRangeException
|
||||
format: @"in removeObjectAtIndex:, index %d is out of range",
|
||||
format: @"in removeObjectAtIndex:, index %"PRIuPTR" is out of range",
|
||||
index];
|
||||
}
|
||||
obj = _contents_array[index];
|
||||
|
@ -467,7 +467,7 @@ RCS_ID("$Id$")
|
|||
if (index >= _count)
|
||||
{
|
||||
[NSException raise: NSRangeException format:
|
||||
@"in replaceObjectAtIndex:withObject:, index %d is out of range",
|
||||
@"in replaceObjectAtIndex:withObject:, index %"PRIuPTR" is out of range",
|
||||
index];
|
||||
}
|
||||
|
||||
|
@ -495,7 +495,7 @@ RCS_ID("$Id$")
|
|||
if (index1 >= _count || index2>=_count)
|
||||
{
|
||||
[NSException raise: NSRangeException format:
|
||||
@"in exchangeObjectAtIndex:withObjectAtIndex:, index %d is out of range",
|
||||
@"in exchangeObjectAtIndex:withObjectAtIndex:, index %"PRIuPTR" is out of range",
|
||||
(index1 >= _count ? index1 : index2)];
|
||||
}
|
||||
|
||||
|
|
|
@ -119,9 +119,9 @@ IVarInString(const char* _type, void* _value)
|
|||
{
|
||||
id *pvalue = (id*)_value;
|
||||
return [NSString stringWithFormat:
|
||||
@"object:%ld Class:%s Description:%@",
|
||||
(long)(*pvalue),
|
||||
[*pvalue class],
|
||||
@"object:%p Class:%@ Description:%@",
|
||||
*pvalue,
|
||||
NSStringFromClass([*pvalue class]),
|
||||
objectDescription(*pvalue)];
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -246,13 +246,13 @@ RCS_ID("$Id$")
|
|||
|
||||
if (!_masterObject)
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: no masterObject",
|
||||
format: @"%@ -- %@ 0x%p: no masterObject",
|
||||
NSStringFromSelector(_cmd), NSStringFromClass([self class]),
|
||||
self];
|
||||
|
||||
if (!_detailKey)
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: no detailKey",
|
||||
format: @"%@ -- %@ 0x%p: no detailKey",
|
||||
NSStringFromSelector(_cmd), NSStringFromClass([self class]),
|
||||
self];
|
||||
|
||||
|
@ -266,13 +266,13 @@ RCS_ID("$Id$")
|
|||
{
|
||||
if (!_masterObject)
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: no masterObject",
|
||||
format: @"%@ -- %@ 0x%p: no masterObject",
|
||||
NSStringFromSelector(_cmd), NSStringFromClass([self class]),
|
||||
self];
|
||||
|
||||
if (!_detailKey)
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: no detailKey",
|
||||
format: @"%@ -- %@ 0x%p: no detailKey",
|
||||
NSStringFromSelector(_cmd), NSStringFromClass([self class]),
|
||||
self];
|
||||
|
||||
|
|
|
@ -2473,7 +2473,7 @@ _mergeValueForKey(id obj, id value,
|
|||
|
||||
if (gid == nil)
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: globalID for object 0x%x not found",
|
||||
format: @"%@ -- %@ 0x%p: globalID for object 0x%p not found",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self,
|
||||
|
@ -3935,7 +3935,7 @@ static BOOL usesContextRelativeEncoding = NO;
|
|||
|
||||
|
||||
|
||||
desc = [NSString stringWithFormat: @"<%p:\nunprocessedChanges [nb:%d]=%p %@\n\nunprocessedDeletes [nb:%d]=%p %@\n\nunprocessedInserts[nb:%d]=%p %@>\n",
|
||||
desc = [NSString stringWithFormat: @"<%p:\nunprocessedChanges [nb:%"PRIuPTR"]=%p %@\n\nunprocessedDeletes [nb:%"PRIuPTR"]=%p %@\n\nunprocessedInserts[nb:%"PRIuPTR"]=%p %@>\n",
|
||||
self,
|
||||
NSCountHashTable(_unprocessedChanges),
|
||||
_unprocessedChanges,
|
||||
|
@ -3958,7 +3958,7 @@ static BOOL usesContextRelativeEncoding = NO;
|
|||
|
||||
|
||||
|
||||
desc = [NSString stringWithFormat: @"<%p:\nchangedObjects [nb:%d]=%p %@\n\ndeletedObjects [nb:%d]=%p %@\n\ninsertedObjects [nb:%d]=%p %@>\n",
|
||||
desc = [NSString stringWithFormat: @"<%p:\nchangedObjects [nb:%"PRIuPTR"]=%p %@\n\ndeletedObjects [nb:%"PRIuPTR"]=%p %@\n\ninsertedObjects [nb:%"PRIuPTR"]=%p %@>\n",
|
||||
self,
|
||||
NSCountHashTable(_changedObjects),
|
||||
_changedObjects,
|
||||
|
|
|
@ -130,7 +130,7 @@ static Class EOFaultClass = NULL;
|
|||
+ (void)doesNotRecognizeSelector: (SEL)selector
|
||||
{
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: selector \"%@\" not recognized",
|
||||
format: @"%@ -- %@ 0x%p: selector \"%@\" not recognized",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self,
|
||||
|
@ -417,7 +417,7 @@ static Class EOFaultClass = NULL;
|
|||
- (void)doesNotRecognizeSelector: (SEL)selector
|
||||
{
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: selector \"%@\" not recognized",
|
||||
format: @"%@ -- %@ 0x%p: selector \"%@\" not recognized",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self,
|
||||
|
|
|
@ -108,7 +108,7 @@ RCS_ID("$Id$")
|
|||
|
||||
- (NSString *)descriptionForObject: object
|
||||
{
|
||||
return [NSString stringWithFormat: @"%@ (EOFault 0x%08x)",
|
||||
return [NSString stringWithFormat: @"%@ (EOFault 0x%p)",
|
||||
NSStringFromClass(_targetClass), object];
|
||||
}
|
||||
|
||||
|
|
|
@ -169,7 +169,7 @@ static NSRecursiveLock *allGenericRecordsLock = nil;
|
|||
if (!classDesc)
|
||||
{
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: attempt to initialize object with nil classDescription",
|
||||
format: @"%@ -- %@ 0x%p: attempt to initialize object with nil classDescription",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self];
|
||||
|
@ -971,7 +971,7 @@ You can override this to exclude properties manually handled by derived object *
|
|||
|
||||
[allGenericRecordsLock unlock];
|
||||
|
||||
NSDebugMLog(@"CALCULATE STOPEXC", "");
|
||||
NSDebugMLog(@"CALCULATE STOPEXC");
|
||||
[localException raise];
|
||||
}
|
||||
NS_ENDHANDLER;
|
||||
|
|
|
@ -238,7 +238,7 @@ RCS_ID("$Id$")
|
|||
- (NSString *) description
|
||||
{
|
||||
NSString *selectorString;
|
||||
selectorString = [isa stringForOperatorSelector: _selector];
|
||||
selectorString = [[self class] stringForOperatorSelector: _selector];
|
||||
if (selectorString == nil)
|
||||
{
|
||||
selectorString = NSStringFromSelector(_selector);
|
||||
|
@ -254,7 +254,7 @@ RCS_ID("$Id$")
|
|||
- (NSString *) debugDescription
|
||||
{
|
||||
NSString *selectorString;
|
||||
selectorString = [isa stringForOperatorSelector: _selector];
|
||||
selectorString = [[self class] stringForOperatorSelector: _selector];
|
||||
if (selectorString == nil)
|
||||
{
|
||||
selectorString = NSStringFromSelector(_selector);
|
||||
|
|
|
@ -791,7 +791,7 @@ class instances should implements -initWithKeyValueUnarchiver: **/
|
|||
}
|
||||
NS_HANDLER
|
||||
{
|
||||
NSDebugMLLog(@"gsdb", @"EOKeyValueUnarchiver",@"EXCEPTION:%@ (%@) [%s %d]",
|
||||
NSDebugMLLog(@"gsdb", @"EOKeyValueUnarchiver, EXCEPTION:%@ (%@) [%s %d]",
|
||||
localException,
|
||||
[localException reason],
|
||||
__FILE__,
|
||||
|
|
|
@ -132,7 +132,7 @@ __attribute__((objc_root_class))
|
|||
- (void) unableToSetNilForKey: (NSString *)key
|
||||
{
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: Given nil value to set for key \"%@\"",
|
||||
format: @"%@ -- %@ 0x%p: Given nil value to set for key \"%@\"",
|
||||
NSStringFromSelector(_cmd), NSStringFromClass([self class]),
|
||||
self, key];
|
||||
}
|
||||
|
|
|
@ -314,7 +314,7 @@ RCS_ID("$Id$")
|
|||
- (NSString *) description
|
||||
{
|
||||
NSString *selectorString;
|
||||
selectorString = [isa stringForOperatorSelector: _selector];
|
||||
selectorString = [[self class] stringForOperatorSelector: _selector];
|
||||
if (selectorString == nil)
|
||||
{
|
||||
selectorString = NSStringFromSelector(_selector);
|
||||
|
@ -330,7 +330,7 @@ RCS_ID("$Id$")
|
|||
- (NSString *) debugDescription
|
||||
{
|
||||
NSString *selectorString;
|
||||
selectorString = [isa stringForOperatorSelector: _selector];
|
||||
selectorString = [[self class] stringForOperatorSelector: _selector];
|
||||
if (selectorString == nil)
|
||||
{
|
||||
selectorString = NSStringFromSelector(_selector);
|
||||
|
@ -368,7 +368,7 @@ RCS_ID("$Id$")
|
|||
else if (requiresAllVariables)
|
||||
{
|
||||
[NSException raise: EOQualifierVariableSubstitutionException
|
||||
format: @"%@ -- %@ 0x%x: Value for '%@' not found in binding resolution",
|
||||
format: @"%@ -- %@ 0x%p: Value for '%@' not found in binding resolution",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self,
|
||||
|
|
|
@ -183,7 +183,7 @@ RCS_ID("$Id$")
|
|||
|
||||
for (i = 0; i < _count; i++)
|
||||
{
|
||||
dscr = [dscr stringByAppendingFormat: @"%@ [%d] ",
|
||||
dscr = [dscr stringByAppendingFormat: @"%@ [%"PRIuPTR"] ",
|
||||
_keys[i],
|
||||
i];
|
||||
}
|
||||
|
@ -490,7 +490,7 @@ RCS_ID("$Id$")
|
|||
NSString *dscr;
|
||||
NSMutableString *offsets = [NSMutableString string];
|
||||
NSUInteger i;
|
||||
int count = [_destinationDescription count];
|
||||
NSUInteger count = [_destinationDescription count];
|
||||
|
||||
dscr = [NSString stringWithFormat: @"<%s %p - ",
|
||||
object_getClassName(self),
|
||||
|
@ -501,7 +501,7 @@ RCS_ID("$Id$")
|
|||
[_destinationDescription description]];
|
||||
|
||||
for (i = 0; i < count; i++)
|
||||
[offsets appendFormat: @" %d", _sourceOffsetForDestinationOffset[i]];
|
||||
[offsets appendFormat: @" %"PRIuPTR, _sourceOffsetForDestinationOffset[i]];
|
||||
|
||||
dscr = [dscr stringByAppendingFormat:
|
||||
@"\nsourceOffsetForDestinationOffset:%@>", offsets];
|
||||
|
|
|
@ -90,12 +90,12 @@ NSString *EOCooperatingObjectStoreNeeded = @"EOCooperatingObjectStoreNeeded";
|
|||
|
||||
- (void)dealloc
|
||||
{
|
||||
NSDebugMLog(@"dealloc coordinator", "");
|
||||
NSDebugMLog(@"dealloc coordinator");
|
||||
DESTROY(_stores);
|
||||
DESTROY(_userInfo);
|
||||
|
||||
[super dealloc];
|
||||
NSDebugMLog(@"dealloc coordinator end", "");
|
||||
NSDebugMLog(@"dealloc coordinator end");
|
||||
}
|
||||
|
||||
- (void)addCooperatingObjectStore: (EOCooperatingObjectStore *)store
|
||||
|
|
|
@ -649,7 +649,7 @@ static SEL eqSel;
|
|||
[NSNumber numberWithUnsignedInteger: count], @"Count",
|
||||
self, @"Array", nil, nil];
|
||||
|
||||
reason = [NSString stringWithFormat: @"Index %d is out of range %d (in '%@')", index, count, NSStringFromSelector(sel)];
|
||||
reason = [NSString stringWithFormat: @"Index %"PRIuPTR" is out of range %"PRIuPTR" (in '%@')", index, count, NSStringFromSelector(sel)];
|
||||
|
||||
exception = [NSException exceptionWithName: NSRangeException
|
||||
reason: reason
|
||||
|
|
|
@ -514,10 +514,8 @@ getKey(const unichar **cFormat,
|
|||
{
|
||||
if (!GDL2_isLegalDBName(key))
|
||||
{
|
||||
NSString *format
|
||||
= [NSString stringWithFormat: @"illegal qualifier variable $%@",key];
|
||||
[NSException raise:NSInvalidArgumentException
|
||||
format:format];
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"illegal qualifier variable $%@", key];
|
||||
}
|
||||
key = (id)[[EOQualifierVariable alloc] initWithKey:key];
|
||||
}
|
||||
|
@ -675,7 +673,7 @@ _qualifierWithArgs(id self, SEL _cmd, NSString *format, NSArray *array, va_list
|
|||
if (!operatorSelector)
|
||||
{
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: no operator or unknown operator: '%@'",
|
||||
format: @"%@ -- %@ 0x%p: no operator or unknown operator: '%@'",
|
||||
NSStringFromClass([self class]),
|
||||
NSStringFromSelector(_cmd),
|
||||
self,
|
||||
|
@ -789,7 +787,7 @@ _qualifierWithArgs(id self, SEL _cmd, NSString *format, NSArray *array, va_list
|
|||
{
|
||||
if (qualifier == nil)
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: missing qualifier",
|
||||
format: @"%@ -- %@ 0x%p: missing qualifier",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]), self];
|
||||
|
||||
|
@ -883,7 +881,7 @@ _qualifierWithArgs(id self, SEL _cmd, NSString *format, NSArray *array, va_list
|
|||
{
|
||||
if (!key)
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"%@ -- %@ 0x%x: nil key",
|
||||
format: @"%@ -- %@ 0x%p: nil key",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self];
|
||||
|
@ -911,10 +909,11 @@ _qualifierWithArgs(id self, SEL _cmd, NSString *format, NSArray *array, va_list
|
|||
if (stop)
|
||||
{
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
format: @"%@ -- %@ 0x%x: invalid key '%@'",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
key];
|
||||
format: @"%@ -- %@ 0x%p: invalid key '%@'",
|
||||
NSStringFromSelector(_cmd),
|
||||
NSStringFromClass([self class]),
|
||||
self,
|
||||
key];
|
||||
} ;
|
||||
};
|
||||
//TODO
|
||||
|
|
|
@ -174,7 +174,7 @@ RCS_ID("$Id$")
|
|||
- (NSString *) description
|
||||
{
|
||||
return [NSString stringWithFormat:@"<%@ %p - %@ %@>",
|
||||
NSStringFromClass(isa),
|
||||
NSStringFromClass([self class]),
|
||||
(void*)self,
|
||||
_key,
|
||||
NSStringFromSelector(_selector)];
|
||||
|
|
Loading…
Reference in a new issue