chiark / gitweb /
Change parameters of moveto() and lineto() to signed
authorBen Harris <bjh21@bjh21.me.uk>
Mon, 16 Dec 2024 21:40:36 +0000 (21:40 +0000)
committerBen Harris <bjh21@bjh21.me.uk>
Mon, 16 Dec 2024 21:40:36 +0000 (21:40 +0000)
The corresponding members of struct vec are signed, as are most of the
arguments passed to the functions, so it's silly that the parameters
themselves are unsigned.  This takes the number of warnings under
clang -Weverything down from 126 to 30.

This doesn't cause any change to the output TTX files.

bedstead.c

index 6a791ef1890ed0d8d299464f103450cb596ed96f..200d69f2daa3b948b67a1b26b8ff50c3686e080a 100644 (file)
@@ -3702,7 +3702,7 @@ clearpath(void)
 }
 
 static void
-moveto(unsigned x, unsigned y)
+moveto(int x, int y)
 {
        struct point *p = &points[nextpoint++];
 
@@ -3711,7 +3711,7 @@ moveto(unsigned x, unsigned y)
 }
 
 static void
-lineto(unsigned x, unsigned y)
+lineto(int x, int y)
 {
        struct point *p = &points[nextpoint++];