mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-21 03:05:15 +00:00
vector casts never reinterpret bits
llvm-svn: 27354
This commit is contained in:
parent
3c994295fe
commit
d9ca6b5bfc
@ -75,6 +75,11 @@ const Type *Type::getPrimitiveType(TypeID IDNumber) {
|
||||
//
|
||||
bool Type::isLosslesslyConvertibleTo(const Type *Ty) const {
|
||||
if (this == Ty) return true;
|
||||
|
||||
// Packed type conversions are always bitwise.
|
||||
if (isa<PackedType>(this) && isa<PackedType>(Ty))
|
||||
return true;
|
||||
|
||||
if ((!isPrimitiveType() && !isa<PointerType>(this)) ||
|
||||
(!isa<PointerType>(Ty) && !Ty->isPrimitiveType())) return false;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user