https://bugs.llvm.org/show_bug.cgi?id=34951

            Bug ID: 34951
           Summary: invalid argument type 'VMutex' to unary expression on
                    requires_capability
           Product: new-bugs
           Version: 4.0
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedb...@nondot.org
          Reporter: wsny...@wsnyder.org
                CC: llvm-bugs@lists.llvm.org

Created attachment 19276
  --> https://bugs.llvm.org/attachment.cgi?id=19276&action=edit
c11_thread_safety2.cpp

I am converting code to use thread-safety negative capabilities based on this:

https://clang.llvm.org/docs/ThreadSafetyAnalysis.html

Perhaps I am doing something wrong, but I can't find any appropriate hints on
the web as to what this could be.

This code (full example attached)

    void clear() __attribute__ ((requires_capability(!m_mutex))) {

gives

 c11_thread_safety2.cpp:62:54: error: invalid argument type 'VMutex' to unary
expression
     void clear() __attribute__ ((requires_capability(!m_mutex))) {
                                                      ^~~~~~~~

on Ubuntu 16.04 LTS,
clang version 3.8.0-2ubuntu3 (tags/RELEASE_380/final)
Target: x86_64-pc-linux-gnu
Thread model: posix

Likewise:
clang version 4.0.1-6 (tags/RELEASE_401/final)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to