This is an archive of the discontinued LLVM Phabricator instance.

[ThreadSafetyAnalysis] Fix isCapabilityExpr
ClosedPublic

Authored by kongyi on Dec 14 2017, 12:17 AM.

Details

Summary

There are many more expr types that can be a capability expr, like
CXXThisExpr, CallExpr, MemberExpr. Instead of enumerating all of them,
just check typeHasCapability for any type given, which is not expensive.

Also add & and * operators to allowed unary operators.

Diff Detail

Repository
rL LLVM

Event Timeline

kongyi created this revision.Dec 14 2017, 12:17 AM

Hi.
I don't want to hijack the thread, but is PR32954 likely unrelated to this fix, and the problem (if it is a bug) is likely elsewhere?

Hi.
I don't want to hijack the thread, but is PR32954 likely unrelated to this fix, and the problem (if it is a bug) is likely elsewhere?

Should be unrelated.

aaron.ballman accepted this revision.Dec 14 2017, 12:24 PM
aaron.ballman added a subscriber: aaron.ballman.

This LGTM, but you should wait to commit for a few days in case @delesley has any concerns.

This revision is now accepted and ready to land.Dec 14 2017, 12:24 PM
delesley accepted this revision.Dec 14 2017, 2:23 PM
This revision was automatically updated to reflect the committed changes.