Move to newer clang annotations
Also enable -Wthread-safety-negative.
Changes:
Switch to capabilities and negative capabilities.
Future work:
Use capabilities to implement uninterruptible annotations to work
with AssertNoThreadSuspension.
Bug: 20072211
Change-Id: I42fcbe0300d98a831c89d1eff3ecd5a7e99ebf33
diff --git a/runtime/oat_file.h b/runtime/oat_file.h
index 7c4ef8b..27f8677 100644
--- a/runtime/oat_file.h
+++ b/runtime/oat_file.h
@@ -215,7 +215,7 @@
const OatDexFile* GetOatDexFile(const char* dex_location,
const uint32_t* const dex_location_checksum,
bool exception_if_not_found = true) const
- LOCKS_EXCLUDED(secondary_lookup_lock_);
+ REQUIRES(!secondary_lookup_lock_);
const std::vector<const OatDexFile*>& GetOatDexFiles() const {
return oat_dex_files_storage_;