This is an archive of the discontinued LLVM Phabricator instance.

Fix -Wunused-result warnings in LLDB
ClosedPublic

Authored by rnk on Nov 14 2019, 3:29 PM.

Details

Summary

Three uses of try_lock intentionally ignore the result. Make that
explicit with a void cast.

Add what appears to be a missing return in the clang expression parser
code. It's a functional change, but presumably the right one.

Diff Detail

Event Timeline

rnk created this revision.Nov 14 2019, 3:29 PM
Herald added a project: Restricted Project. · View Herald TranscriptNov 14 2019, 3:29 PM
amccarth accepted this revision.Nov 14 2019, 3:50 PM

LGTM.

It's too bad that pattern is repeated three times, including the explanatory comment.

This revision is now accepted and ready to land.Nov 14 2019, 3:50 PM

There's a PP above each instance of this code explaining why it's okay if we don't get the API lock, since that's a bit of a tricky point. So if you want to add a comment, it would be better to say "see explanation above".

This revision was automatically updated to reflect the committed changes.