[PATCH] D153001: [clang][ThreadSafety] Add __builtin_instance_member (WIP)
Timm Bäder via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 28 01:03:11 PDT 2023
tbaeder added a comment.
Didn't remember and re-checked, using it that way makes the implementation harder I think:
tsa2.c:7:54: error: incomplete definition of type 'struct Mutex'
7 | int counter GUARDED_BY(__builtin_instance_member(M)->M);
| ^
tsa2.c:6:10: note: forward declaration of 'struct Mutex'
6 | struct Mutex *M;
| ^
1 error generated.
and I didn't immediately know how to fix that.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D153001/new/
https://reviews.llvm.org/D153001
More information about the cfe-commits
mailing list