| //===- TernaryOp.h --------------------------------------------------------===// |
| // This file is distributed under the University of Illinois Open Source |
| // License. See LICENSE.TXT for details. |
| //===----------------------------------------------------------------------===// |
| #ifndef MCLD_SCRIPT_TERNARYOP_H_ |
| #define MCLD_SCRIPT_TERNARYOP_H_ |
| #include "mcld/Script/Operator.h" |
| * \brief This class defines the interfaces to an binary operator token. |
| template <Operator::Type TYPE> |
| class TernaryOp : public Operator { |
| TernaryOp() : Operator(Operator::TERNARY, TYPE) { |
| m_pOperand[0] = m_pOperand[1] = m_pOperand[2] = NULL; |
| IntOperand* eval(const Module& pModule, const TargetLDBackend& pBackend); |
| void appendOperand(Operand* pOperand) { |
| m_pOperand[m_Size++] = pOperand; |
| IntOperand* TernaryOp<Operator::TERNARY_IF>::eval(const Module&, |
| IntOperand* TernaryOp<Operator::DATA_SEGMENT_ALIGN>::eval( |
| #endif // MCLD_SCRIPT_TERNARYOP_H_ |