You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: parser/README.md
+17-1Lines changed: 17 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -216,6 +216,20 @@ When a parameter is a function pointer typedef, the complete function signature
216
216
}
217
217
```
218
218
219
+
### Parameter or Return Type with Typedef Alias
220
+
221
+
When a parameter or return type is named via a plain (non-function-pointer) typedef, such as `using MenuId = uint32_t;`, the resolved type is used and the original typedef name (plus its Doxygen description, if any) is preserved in an `alias` structure:
222
+
223
+
```json
224
+
{
225
+
"type": "uint32",
226
+
"description": "A handle to the created menu.",
227
+
"alias": {
228
+
"name": "MenuId"
229
+
}
230
+
}
231
+
```
232
+
219
233
### Field Descriptions
220
234
221
235
-`name`: Function name
@@ -228,11 +242,13 @@ When a parameter is a function pointer typedef, the complete function signature
228
242
-`ref`: Boolean indicating if it's a reference parameter
229
243
-`description`: Parameter description from Doxygen comments (if available)
230
244
-`enum`: (Optional) Full enum structure if parameter is an enum type
245
+
-`alias`: (Optional) `{name, description}` of the typedef if the parameter is named via a plain typedef (e.g. `MenuId`)
231
246
-`prototype`: (Optional) Full function signature if parameter is a function pointer typedef
232
247
-`retType`: Return type object:
233
248
-`type`: Mapped return type
234
249
-`description`: Return description from Doxygen comments (if available)
235
250
-`enum`: (Optional) Full enum structure if return type is an enum
251
+
-`alias`: (Optional) `{name, description}` of the typedef if the return type is named via a plain typedef
236
252
237
253
## Advanced Features
238
254
@@ -282,7 +298,7 @@ The script maps C++ types to simplified types:
282
298
|`Vector`, `QAngle`, `plg::vec3`|`vec3`|
283
299
| Enums | Base type (e.g., `uint8`, `int32`) + enum structure |
284
300
| Function pointer typedefs |`function` + prototype structure |
285
-
| Other typedefs |`?`|
301
+
| Other typedefs (e.g. `using MenuId = uint32_t;`) | Underlying type (e.g. `uint32`), resolved recursively through typedef chains + alias structure|
286
302
287
303
Pointers (except `void*`) are mapped to `ptr64`, and unknown types default to `?`.
0 commit comments