X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FInstrTypes.h;h=7441a104b56f8b5c2847c569875cfa874302a514;hb=fc82fabe00b0b820e3c0d7fc9e289bace0295f11;hp=a6a8fff40ce9707fdca087ee439378ebca94bbdb;hpb=edfd10de873a424a8516a6dbf5feb8168efc462d;p=oota-llvm.git diff --git a/include/llvm/InstrTypes.h b/include/llvm/InstrTypes.h index a6a8fff40ce..7441a104b56 100644 --- a/include/llvm/InstrTypes.h +++ b/include/llvm/InstrTypes.h @@ -2,8 +2,8 @@ // // The LLVM Compiler Infrastructure // -// This file was developed by the LLVM research group and is distributed under -// the University of Illinois Open Source License. See LICENSE.TXT for details. +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// // @@ -398,8 +398,14 @@ public: BasicBlock *InsertAtEnd ///< The block to insert the instruction into ); + /// @brief Check whether it is valid to call getCastOpcode for these types. + static bool isCastable( + const Type *SrcTy, ///< The Type from which the value should be cast. + const Type *DestTy ///< The Type to which the value should be cast. + ); + /// Returns the opcode necessary to cast Val into Ty using usual casting - /// rules. + /// rules. /// @brief Infer the opcode for cast operand and type static Instruction::CastOps getCastOpcode( const Value *Val, ///< The value to cast