[libc-commits] [libc] [libc] Implement vasprintf and asprintf (PR #98824)
Michael Jones via libc-commits
libc-commits at lists.llvm.org
Mon Jul 29 13:45:54 PDT 2024
================
@@ -934,6 +934,13 @@ def StdC : StandardSpec<"stdc"> {
ArgSpec<ConstCharRestrictedPtr>,
ArgSpec<VarArgType>]
>,
+ FunctionSpec<
----------------
michaelrj-google wrote:
since we're moving to new headergen soon, you also need to add these functions to the config for that. Here's how:
in `libc/newhdrgen/yaml/stdio.yaml` add two new items to the list of functions:
```
- name: asprintf
standards:
- GNUExtensions
return_type: int
arguments:
- type: char **__restrict
- type: const char *__restrict
- type: ...
- name: vasprintf
standards:
- GNUExtensions
return_type: int
arguments:
- type: char **__restrict
- type: const char *__restrict
- type: va_list
```
https://github.com/llvm/llvm-project/pull/98824
More information about the libc-commits
mailing list