[llvm-commits] [llvm] r107199 - /llvm/trunk/include/llvm/ADT/SmallPtrSet.h
Chris Lattner
clattner at apple.com
Wed Jun 30 08:20:41 PDT 2010
>>>
>>> Ignoring overflow, NextPowerOfTwo(x) is always strictly greater than x.
>>
>> are you sure? C++ templates make my head hurt, but as far as I can see it
>> works as follows.
>
> Oh wait, there's a template?
>
> I was talking about the function in MathExtras.h:
>
> /// NextPowerOf2 - Returns the next power of two (in 64-bits)
> /// that is strictly greater than A. Returns zero on overflow.
Please change the comment to be "greater than or equal to A" at least :)
-Chris
More information about the llvm-commits
mailing list