mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 17:10:48 +00:00
Add 'hope' because gnustep runtime fails to do atomic access
This commit is contained in:
parent
d622530819
commit
6bceca9962
1 changed files with 5 additions and 0 deletions
|
@ -112,11 +112,16 @@ main(int argc, char *argv[])
|
|||
objc_setAssociatedObject(o, (void*)1, assoc1, OBJC_ASSOCIATION_RETAIN);
|
||||
PASS(u + 1 == [assoc1 retainCount],
|
||||
"OBJC_ASSOCIATION_RETAIN does retain")
|
||||
|
||||
// atomic association apparently does not work in gnustep runtime
|
||||
testHopeful = YES;
|
||||
ENTER_POOL
|
||||
PASS(objc_getAssociatedObject(o, (void*)1) == assoc1,
|
||||
"can get retained associated object")
|
||||
PASS(u + 2 == [assoc1 retainCount], "getting retains associated value")
|
||||
LEAVE_POOL
|
||||
testHopeful = NO;
|
||||
|
||||
ENTER_POOL
|
||||
objc_setAssociatedObject(o, (void*)1, assoc2, OBJC_ASSOCIATION_RETAIN);
|
||||
LEAVE_POOL
|
||||
|
|
Loading…
Reference in a new issue