rpav / c2ffi

Clang-based FFI wrapper generator
GNU Lesser General Public License v2.1
234 stars 39 forks source link

Function typedefs return as `:function-pointer` #122

Open mbekkomo opened 5 months ago

mbekkomo commented 5 months ago
typedef void (*func)(void);

Returns:

{
  "tag": "typedef",
  "name": "func",
  "type": {
    "tag": ":function-pointer"
  },
  // ...
}

It doesn't have parameters and return-type properties.

mbekkomo commented 5 months ago

Expected result are


{
  "tag": "typedef",
  "name": "func",
  "type": {
    "tag": ":function-pointer",
    "parameters": [
      {
        "tag": ":void"
      }
    ],
    "return-type": {
      "tag": ":void"
    }
  },
  // ...
}
rpav commented 3 months ago

Sorry I missed this; any idea if this is a regression?