如何在Objective-C中转换间接指针

Hur*_*rkS 8 pointers casting objective-c ios

我正在尝试在我的钥匙串上做一些工作,并在这里遵循这个教程 不幸的是我得到以下错误,它谈到搜索钥匙串

Cast of an indirect pointer to an Objective-C pointer to 'CFTypeRef *' (aka 'const void **') is disallowed with ARC
Run Code Online (Sandbox Code Playgroud)

这就是代码的样子

 OSStatus status = SecItemCopyMatching((__bridge CFDictionaryRef)searchDictionary,(CFTypeRef *)&result);
Run Code Online (Sandbox Code Playgroud)

任何帮助提供关于如何投射间接指针的正确代码将非常感激.

cnc*_*ool 28

使用void*代替:

 OSStatus status = SecItemCopyMatching((__bridge CFDictionaryRef)searchDictionary,(void *)&result);
Run Code Online (Sandbox Code Playgroud)