Bug 13708 – [REG2.067a] IN contract failure in std.bitmanip.opOpAssign

Status
RESOLVED
Resolution
INVALID
Severity
regression
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-11-11T02:23:00Z
Last change time
2014-11-11T10:40:41Z
Assigned to
nobody
Creator
mk

Comments

Comment #0 by mk — 2014-11-11T02:23:09Z
import std.bitmanip; void main() { BitArray bit1; BitArray bit2; bit1.init([0,0]); bit2.init([1]); bit1 &= bit2; } ============================================== core.exception.AssertError@std/bitmanip.d(1298): Assertion failure ---------------- ./bitbug(void std.bitmanip.__unittest_fail(int)+0) [0x8075620] ./bitbug(pure nothrow std.bitmanip.BitArray std.bitmanip.BitArray.opOpAssign!("&").opOpAssign(const(std.bitmanip.BitArray))+0x26) [0x8071bbe] ./bitbug(_Dmain+0x62) [0x8071b92] Introduced by: https://github.com/D-Programming-Language/phobos/commit/782afe659ffe215e78a5bc4c244733f688a1ed6a
Comment #1 by safety0ff.bugz — 2014-11-11T04:45:07Z
With which version did that code work without error? That code violates the contract and the error should be raised with and without the identified commit.
Comment #2 by mk — 2014-11-11T10:40:41Z
Damn those late night posts :) Yeah I thought it would be correct, but somehow I didn't get the assert after reverting your patch, but now it seems like it's build releated on my side.