This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] [test] nasty_mutex::operator& should return nullptr, like nasty_list above it.
ClosedPublic

Authored by STL_MSFT on Apr 28 2016, 5:13 PM.

Details

Summary

[libcxx] [test] nasty_mutex::operator& should return nullptr, like nasty_list above it.

Fixes MSVC "error C4716: 'nasty_mutex::operator&': must return a value".

Diff Detail

Event Timeline

STL_MSFT updated this revision to Diff 55510.Apr 28 2016, 5:13 PM
STL_MSFT retitled this revision from to [libcxx] [test] nasty_mutex::operator& should return nullptr, like nasty_list above it..
STL_MSFT updated this object.
STL_MSFT added reviewers: EricWF, mclow.lists.
STL_MSFT added a subscriber: cfe-commits.
EricWF accepted this revision.Apr 28 2016, 5:50 PM
EricWF edited edge metadata.

Well arguable it should be no return or even better it should have an "= delete" so it's diagnosed even if it's not called.

For now this works though.

This revision is now accepted and ready to land.Apr 28 2016, 5:50 PM
EricWF closed this revision.Apr 28 2016, 5:51 PM

r267961.

[Eric Fiselier]

Well arguable it should be no return or even better it should
have an "= delete" so it's diagnosed even if it's not called.
For now this works though.

Agreed - I just wasn't sure what this code was trying to do, and I figured it should be consistent. I'm trying to keep my patches minimally intrusive until I understand your tests better.

Thanks,
STL