[cfe-dev] @synchronized

Keith Bauer onesadcookie at gmail.com
Wed Jan 16 17:36:45 PST 2008


@synchronized doesn't seem to be supported at all by the ObjC parser:

CookieJar:~ keith$ cat > test.m
void foo(id o) { @synchronized(o) {} }
CookieJar:~ keith$ gcc -Wall -W -c test.m
CookieJar:~ keith$ clang -fsyntax-only test.m
test.m:1:18: error: unexpected '@' in program
void foo(id o) { @synchronized(o) {} }
                 ^
test.m:1:38: error: expected ';' after expression
void foo(id o) { @synchronized(o) {} }
                                     ^
Assertion failed: (E && "ActOnExprStmt(): missing expression"),
function ActOnExprStmt, file SemaStmt.cpp, line 27.

-Keith



More information about the cfe-dev mailing list