// don't support specifying the backing type for an enum
/// LHSKind - The NodeKind of the left hand side, \see getLHSKind().
unsigned char LHSKind;
- /// RHSKind - The NodeKind of the left hand side, \see getLHSKind().
+ /// RHSKind - The NodeKind of the right hand side, \see getRHSKind().
unsigned char RHSKind;
private:
assert(isValid() && "Invalid twine!");
}
+ /// Since the intended use of twines is as temporary objects, assignments
+ /// when concatenating might cause undefined behavior or stack corruptions
+ Twine &operator=(const Twine &Other) LLVM_DELETED_FUNCTION;
+
/// isNull - Check for the null twine.
bool isNull() const {
return getLHSKind() == NullKind;
/// getLHSKind - Get the NodeKind of the left-hand side.
NodeKind getLHSKind() const { return (NodeKind) LHSKind; }
- /// getRHSKind - Get the NodeKind of the left-hand side.
+ /// getRHSKind - Get the NodeKind of the right-hand side.
NodeKind getRHSKind() const { return (NodeKind) RHSKind; }
/// printOneChild - Print one child from a twine.
static Twine utohexstr(const uint64_t &Val) {
Child LHS, RHS;
LHS.uHex = &Val;
- RHS.twine = 0;
+ RHS.twine = nullptr;
return Twine(LHS, UHexKind, RHS, EmptyKind);
}