Prefer C++-style casts.

This is based on Item 2 of "More Effective C++". In general, the C++ cast operators are more expressive and easy to find,
e.g. by grep. Using const_cast also shuts up some compiler warnings.
This commit is contained in:
kai
2012-08-02 19:55:29 +02:00
parent 9dad0a6b3b
commit 2dbee75523
21 changed files with 227 additions and 227 deletions

View File

@@ -20,7 +20,7 @@ static LLValue* to_keyti(DValue* aa)
{
// keyti param
assert(aa->type->toBasetype()->ty == Taarray);
TypeAArray * aatype = (TypeAArray*)aa->type->toBasetype();
TypeAArray * aatype = static_cast<TypeAArray*>(aa->type->toBasetype());
return DtoTypeInfoOf(aatype->index, false);
}
#else