An implementation of IsPowerOf2, a trait for determining whether a number is an integer power of 2.
IsPowerOf2