[libc-commits] [PATCH] D122327: [libc] Add implementations of fopen, flose, fread, fwrite and fseek.
Michael Jones via Phabricator via libc-commits
libc-commits at lists.llvm.org
Wed Mar 23 10:41:38 PDT 2022
michaelrj added inline comments.
================
Comment at: libc/src/stdio/fopen.h:16
-struct FILE {
- mtx_t lock;
-
- using write_function_t = size_t(FILE *, const char *, size_t);
-
- write_function_t *write;
-};
+::FILE *fopen(const char *__restrict name, const char *__restrict mode);
----------------
why does this need to specifically be a global namespace FILE?
================
Comment at: libc/src/stdio/fseek.h:16
-struct FILE {
- mtx_t lock;
-
- using write_function_t = size_t(FILE *, const char *, size_t);
-
- write_function_t *write;
-};
+int fseek(FILE *stream, long offset, int whence);
----------------
the other FILEs are specifically global, if that is necessary then this one should be too.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D122327/new/
https://reviews.llvm.org/D122327
More information about the libc-commits
mailing list