// RUN: %clang_cc1 -fsyntax-only -Wthread-safety -verify %s
class__attribute__((shared_capability("mutex")))Mutex{public:voidfunc1()__attribute__((assert_capability(this)));voidfunc2()__attribute__((assert_capability(!this)));const Mutex&operator!()const{return*this;}};classNotACapability{public:voidfunc1()__attribute__((assert_capability(this)));// expected-warning {{'assert_capability' attribute requires arguments whose type is annotated with 'capability' attribute; type here is 'NotACapability *'}}
voidfunc2()__attribute__((assert_capability(!this)));// expected-warning {{'assert_capability' attribute requires arguments whose type is annotated with 'capability' attribute; type here is 'bool'}}
const NotACapability&operator!()const{return*this;}};