]> git.lizzy.rs Git - rust.git/commit
Auto merge of #25527 - inrustwetrust:const-not-overflow, r=alexcrichton
authorbors <bors@rust-lang.org>
Sun, 17 May 2015 23:53:41 +0000 (23:53 +0000)
committerbors <bors@rust-lang.org>
Sun, 17 May 2015 23:53:41 +0000 (23:53 +0000)
commit0cc99f9cc9b59518f618a2c3f5011000e60f922e
tree898be95172a41f2d364bb8bcf5ee2a41c119b105
parente4d56b7b5b68cd5cfb4bb65f974af701ab556241
parentd1605deab864d83e5fd5b4e9749d5fd1320fb1fc
Auto merge of #25527 - inrustwetrust:const-not-overflow, r=alexcrichton

Fixes #23968.
Since the values are stored in a u64 internally, we need to be mask away the
high bits after applying the ! operator. Otherwise, these bits will be set to
one, causing overflow.