[llvm-commits] [PATCH] Handle negative values in StringRef::getAsInteger(unsigned Radix, APInt &).

Chris Lattner clattner at apple.com
Sat Mar 10 13:54:07 PST 2012


On Mar 9, 2012, at 5:01 PM, Michael Spencer wrote:

>> 
>> I'd prefer you to clean up the overload set, but do what you think is best.  Thanks!
>> 
>> -Chris
> 
> Attached is a patch that does this. I chose to go with templates
> because it reduced the amount of repeated code. There is also a test
> that checks all the boundaries for each size both positive and
> negative (for signed values).

LGTM, thanks!



More information about the llvm-commits mailing list