commit e662a3a5d5922a6f3925731ff52363834e1c9d4d
parent 9dfcc04c761ad5d218a1178795398883c0925aba
Author: Roberto E. Vargas Caballero <k0ga@shike2.net>
Date: Mon, 25 May 2026 10:40:29 +0200
cc1: Add \r to cppspaces()
While this is not required (accepted?) by the standard, ignoring
them would help in cases where source code from Win is used in
Unix systems.
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/cmd/scc-cc/cc1/cpp.c b/src/cmd/scc-cc/cc1/cpp.c
@@ -145,7 +145,8 @@ unterminated:
static int
cppspace(int c)
{
- return c == ' ' || c == '\t' || c == '\v' || c == '\n' || c == '\f';
+ return c == ' ' || c == '\t' || c == '\v' ||
+ c == '\n' || c == '\f' || c == '\r';
}
static char *