mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 00:11:26 +00:00
Add casts to avoid compiler warnings bout type of method
This commit is contained in:
parent
09e9354f08
commit
132729e6e0
3 changed files with 13 additions and 9 deletions
|
@ -115,7 +115,8 @@ static SEL objSel;
|
|||
{
|
||||
NSUInteger count = map.nodeCount;
|
||||
SEL sel = @selector(encodeObject:);
|
||||
id (*imp)(id,SEL,id) = [aCoder methodForSelector: sel];
|
||||
id (*imp)(id,SEL,id)
|
||||
= (id (*)(id,SEL,id))[aCoder methodForSelector: sel];
|
||||
GSIMapEnumerator_t enumerator = GSIMapEnumeratorForMap(&map);
|
||||
GSIMapNode node = GSIMapEnumeratorNextNode(&enumerator);
|
||||
|
||||
|
@ -152,7 +153,8 @@ static SEL objSel;
|
|||
id key;
|
||||
id value;
|
||||
SEL sel = @selector(decodeValueOfObjCType:at:);
|
||||
void (*imp)(id,SEL,const char*,void*) = [aCoder methodForSelector: sel];
|
||||
void (*imp)(id,SEL,const char*,void*)
|
||||
= (void (*)(id,SEL,const char*,void*))[aCoder methodForSelector: sel];
|
||||
const char *type = @encode(id);
|
||||
|
||||
[aCoder decodeValueOfObjCType: @encode(NSUInteger)
|
||||
|
@ -220,8 +222,9 @@ static SEL objSel;
|
|||
if (c > 0)
|
||||
{
|
||||
NSEnumerator *e = [other keyEnumerator];
|
||||
id (*nxtObj)(id, SEL) = [e methodForSelector: nxtSel];
|
||||
id (*otherObj)(id, SEL, id) = [other methodForSelector: objSel];
|
||||
id (*nxtObj)(id, SEL) = (id (*)(id,SEL))[e methodForSelector: nxtSel];
|
||||
id (*otherObj)(id, SEL, id)
|
||||
= (id (*)(id,SEL,id))[other methodForSelector: objSel];
|
||||
BOOL isProxy = [other isProxy];
|
||||
NSUInteger i;
|
||||
|
||||
|
@ -293,7 +296,8 @@ static SEL objSel;
|
|||
{
|
||||
GSIMapEnumerator_t enumerator;
|
||||
GSIMapNode node;
|
||||
id (*otherObj)(id, SEL, id) = [other methodForSelector: objSel];
|
||||
id (*otherObj)(id, SEL, id)
|
||||
= (id (*)(id,SEL,id))[other methodForSelector: objSel];
|
||||
|
||||
enumerator = GSIMapEnumeratorForMap(&map);
|
||||
while ((node = GSIMapEnumeratorNextNode(&enumerator)) != 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue