about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorHuon Wilson <dbau.pp+github@gmail.com>2013-04-08 01:26:51 +1000
committerHuon Wilson <dbau.pp+github@gmail.com>2013-04-08 16:35:39 +1000
commit49cdf36d2b993e08833bfdda2563b0c22ee42de7 (patch)
treedbb074de8dcc1ce5ab5e3b45879290f878a3aaac /src/rustllvm/RustWrapper.cpp
parent44d4d6de762f3f9aae1fedcf454c66b79b3ad58d (diff)
downloadrust-49cdf36d2b993e08833bfdda2563b0c22ee42de7.tar.gz
rust-49cdf36d2b993e08833bfdda2563b0c22ee42de7.zip
libcore: from_str_common: correctly signal failure on repeating base 2^n numbers.
A number like 0b1_1111_1111 == 511 would be parsed to Some(255u8) rather than None
by from_str_common, since 255 * 2 + 1 == 255 (mod 256) so the overflow wasn't detected.

Only applied to conversions where the radix was a power of 2, and where all digits
repeated.

Closes #5770.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions