Template Function Rose::BitOps::convertSigned

Template Function Rose::BitOps::convertSigned#

Function Documentation#

template<typename UnsignedTarget, typename UnsignedSource>
inline UnsignedTarget Rose::BitOps::convertSigned(UnsignedSource x)#

Sign extend or truncate a value.

This is identical to convert except when the target value is wider than the source value the new bits of the return value are all set to the most significant bit of the source value.