Add some explicit casts-through-void* to silence warnings about casts that increase the alignment requirements of the pointee (mostly caused by using char* for arithmetic).

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@32219 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
theraven 2011-02-19 15:34:21 +00:00
parent 56cdca569a
commit f31000e770
8 changed files with 25 additions and 21 deletions

View file

@ -50,7 +50,7 @@ static Class CXXExceptionClass;
// TODO: Add an API for registering other classes for other exception types
static Class boxClass(int64_t foo)
{
if (foo == *(int64_t*)"GNUCC++\0")
if (foo == *(int64_t*)(void*)"GNUCC++\0")
{
return CXXExceptionClass;
}
@ -75,7 +75,7 @@ static Class boxClass(int64_t foo)
{
char *ptr = (char*)ex;
ptr -= __builtin_offsetof(struct __cxa_exception, unwindHeader);
return ((struct __cxa_exception*)ptr)->exceptionType;
return ((struct __cxa_exception*)(void*)ptr)->exceptionType;
}
- (void) rethrow
{