reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

Declarations

tools/clang/lib/AST/Interp/Integral.h
   58   template <unsigned OtherBits, bool OtherSigned> friend class Integral;

References

tools/clang/lib/AST/Interp/Boolean.h
   95       Integral<SrcBits, SrcSign> Value) {
  100   static Boolean from(Integral<0, SrcSign> Value) {
tools/clang/lib/AST/Interp/Integral.h
   77   explicit Integral(Integral<SrcBits, SrcSign> V) : V(V.V) {}
   83   bool operator<(Integral RHS) const { return V < RHS.V; }
   84   bool operator>(Integral RHS) const { return V > RHS.V; }
   85   bool operator<=(Integral RHS) const { return V <= RHS.V; }
   86   bool operator>=(Integral RHS) const { return V >= RHS.V; }
   87   bool operator==(Integral RHS) const { return V == RHS.V; }
   88   bool operator!=(Integral RHS) const { return V != RHS.V; }
   94   Integral operator-() const { return Integral(-V); }
   94   Integral operator-() const { return Integral(-V); }
   95   Integral operator~() const { return Integral(~V); }
   95   Integral operator~() const { return Integral(~V); }
   98   explicit operator Integral<DstBits, DstSign>() const {
   99     return Integral<DstBits, DstSign>(V);
  117   Integral<Bits, false> toUnsigned() const {
  118     return Integral<Bits, false>(*this);
  134   ComparisonCategoryResult compare(const Integral &RHS) const {
  140   Integral truncate(unsigned TruncBits) const {
  146     return Integral((V & BitMask) | (Signed && (V & SignBit) ? ExtMask : 0));
  151   static Integral min(unsigned NumBits) {
  152     return Integral(Min);
  154   static Integral max(unsigned NumBits) {
  155     return Integral(Max);
  159   static typename std::enable_if<std::is_integral<T>::value, Integral>::type
  161     return Integral(Value);
  165   static typename std::enable_if<SrcBits != 0, Integral>::type
  166   from(Integral<SrcBits, SrcSign> Value) {
  167     return Integral(Value.V);
  170   template <bool SrcSign> static Integral from(Integral<0, SrcSign> Value) {
  170   template <bool SrcSign> static Integral from(Integral<0, SrcSign> Value) {
  172       return Integral(Value.V.getSExtValue());
  174       return Integral(Value.V.getZExtValue());
  177   static Integral zero() { return from(0); }
  179   template <typename T> static Integral from(T Value, unsigned NumBits) {
  180     return Integral(Value);
  187   static bool increment(Integral A, Integral *R) {
  187   static bool increment(Integral A, Integral *R) {
  188     return add(A, Integral(T(1)), A.bitWidth(), R);
  191   static bool decrement(Integral A, Integral *R) {
  191   static bool decrement(Integral A, Integral *R) {
  192     return sub(A, Integral(T(1)), A.bitWidth(), R);
  195   static bool add(Integral A, Integral B, unsigned OpBits, Integral *R) {
  195   static bool add(Integral A, Integral B, unsigned OpBits, Integral *R) {
  195   static bool add(Integral A, Integral B, unsigned OpBits, Integral *R) {
  199   static bool sub(Integral A, Integral B, unsigned OpBits, Integral *R) {
  199   static bool sub(Integral A, Integral B, unsigned OpBits, Integral *R) {
  199   static bool sub(Integral A, Integral B, unsigned OpBits, Integral *R) {
  203   static bool mul(Integral A, Integral B, unsigned OpBits, Integral *R) {
  203   static bool mul(Integral A, Integral B, unsigned OpBits, Integral *R) {
  203   static bool mul(Integral A, Integral B, unsigned OpBits, Integral *R) {
  261 llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, Integral<Bits, Signed> I) {
tools/clang/lib/AST/Interp/PrimType.h
   42 template <> struct PrimConv<PT_Sint8> { using T = Integral<8, true>; };
   43 template <> struct PrimConv<PT_Uint8> { using T = Integral<8, false>; };
   44 template <> struct PrimConv<PT_Sint16> { using T = Integral<16, true>; };
   45 template <> struct PrimConv<PT_Uint16> { using T = Integral<16, false>; };
   46 template <> struct PrimConv<PT_Sint32> { using T = Integral<32, true>; };
   47 template <> struct PrimConv<PT_Uint32> { using T = Integral<32, false>; };
   48 template <> struct PrimConv<PT_Sint64> { using T = Integral<64, true>; };
   49 template <> struct PrimConv<PT_Uint64> { using T = Integral<64, false>; };