title: Does Swift not work with function pointers?
body: <p>I'm trying to use a C library in Swift, and I'm having trouble calling any function that takes a function pointer as one of it's arguments. For example, part of the lua.h file that I'm trying to use in Swift looks like this:</p>
  
  <pre><code>LUA_API void  (lua_setuservalue) (lua_State *L, int idx);
  
  
  typedef int (*lua_CFunction) (lua_State *L);
  
  LUA_API void  (lua_callk) (lua_State *L, int nargs, int nresults, int ctx,
                         lua_CFunction k);
  </code></pre>
  
  <p>I use the bridging header to get access to the library, and from my Swift code I can call <strong>lua_setuservalue</strong> without any trouble. But if I try to call <strong>lua_callk</strong> I get "use of unresolved identifier 'lua_callk'". If I remove the function pointer from the declaration for <strong>lua_callk</strong>, I no longer get this error. Any help is quite appreciated.</p>