scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | Submodules | README | LICENSE

commit dde31ff4005e93479be77b0cbf7803f43a6c44e1
parent c8b98df43be4c4b8bd2026d517b4962da91a9224
Author: Roberto E. Vargas Caballero <roberto.vargas@midokura.com>
Date:   Tue, 16 Aug 2022 13:50:43 +0200

libc: Whitespace changes

Diffstat:
Msrc/libc/stdio/fgets.c | 2+-
Msrc/libc/stdio/getc.c | 2+-
Msrc/libc/stdio/putc.c | 2+-
Msrc/libc/stdlib/abs.c | 1+
Msrc/libc/stdlib/calloc.c | 1+
Msrc/libc/stdlib/labs.c | 1+
Msrc/libc/stdlib/llabs.c | 1+
7 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/src/libc/stdio/fgets.c b/src/libc/stdio/fgets.c @@ -11,7 +11,7 @@ fgets(char *restrict s, int n, FILE *restrict fp) for (--n; n > 0; --n) { if ((ch = getc(fp)) == EOF) break; - if ((*t++ = ch) == '\n') + if ((*t++ = ch) == '\n') break; } if (ch == EOF && s == t) diff --git a/src/libc/stdio/getc.c b/src/libc/stdio/getc.c @@ -5,5 +5,5 @@ int getc(FILE *fp) { - return (fp->rp >= fp->wp) ? __getc(fp) : *fp->rp++; + return (fp->rp >= fp->wp) ? __getc(fp) : *fp->rp++; } diff --git a/src/libc/stdio/putc.c b/src/libc/stdio/putc.c @@ -5,5 +5,5 @@ int putc(int ch, FILE *fp) { - return (fp->wp >= fp->rp) ? __putc(ch,fp) : (*fp->wp++ = ch); + return (fp->wp >= fp->rp) ? __putc(ch, fp) : (*fp->wp++ = ch); } diff --git a/src/libc/stdlib/abs.c b/src/libc/stdlib/abs.c @@ -1,4 +1,5 @@ #include <stdlib.h> + #undef abs int diff --git a/src/libc/stdlib/calloc.c b/src/libc/stdlib/calloc.c @@ -1,5 +1,6 @@ #include <stdlib.h> #include <string.h> + #undef calloc void * diff --git a/src/libc/stdlib/labs.c b/src/libc/stdlib/labs.c @@ -1,4 +1,5 @@ #include <stdlib.h> + #undef labs long diff --git a/src/libc/stdlib/llabs.c b/src/libc/stdlib/llabs.c @@ -1,4 +1,5 @@ #include <stdlib.h> + #undef llabs long long