Author | Jamozed <[email protected]> |
Date | 2020-09-16 07:36:37 |
Commit | e65742c42d43f63419b5702c1fdb0b7756dafffa |
Parent | 5fb1515bb308a27e17fdf4cb473ce43d2e569ace |
echo: Add comments
Diffstat
M | src/echo.c | | | 4 | ++++ |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/echo.c b/src/echo.c index f0dc755..1d1caf7 100644 --- a/src/echo.c +++ b/src/echo.c @@ -41,6 +41,10 @@ int main(int ac, char *av[]) { (void)ac; } fputc('\n', stdout); return 0; } +/* + Echo a string to stdout character by character. + Escape sequences are processed according to XSI. +*/ static inline void echo(const char *s) { for (const char *p = s; *p; ++p) { if (*p == '\\' && p[1]) switch (*++p) {