I am using a Core Foundations method I borrowed from Apple's useful UIElementUtilities app. The problem is that I wish to update this borrowed method so that it runs under Apple's new Automatic Reference Counting (ARC) system. I have made some progress adapting most of my borrowed methods by inserting the '__bridge' qualifier before variables, however with the method shown below I get the following error after attempting to convert to ARC: "error: Incompatible types casting 'NSString __strong *' to 'CFTypeRef *' (aka 'const void **) with a __bridge cast". How do I make make an acceptable pointer to the 'actionDescription' buffer so that its contents is recast to an NSString?
+ (NSString *)descriptionOfAction:(NSString *)actionName ofUIElement:(AXUIElementRef)element {
NSString * actionDescription = nil;
AXUIElementCopyActionDescription(element, (__bridge CFStringRef)actionName, (__bridge CFStringRef *)&actionDescription);
return actionDescription;
//return [actionDescription autorelease];
}