8 Sep
2014
8 Sep
'14
8:35 a.m.
Hi, I found a bug in MSVC 10.0 that causes a bug in Boost.Optional. I will be trying to find a workaround for the compiler. I would like to ask people with the access to MSVC 11.0 and 12.0 to check if the bug also persist in these newer releases. The following code is expected to compile: struct A { A(int) {} A(A &&) {} }; struct B { operator A() { return A(1); } operator int() { return 0; } }; int main() { A t = B(); } The following code is expected *NOT *to compile: struct A { A(int) {} }; struct B { operator int() { return 0; } }; int main() { A t = B(); } Please let me know what your compiler says. Thanks, &rzej