Thus making clang happy, and leaving the possibility of checking things at run-tmie via extended STTI macro in the future.
Unified · Split
| @@ -93,6 +93,8 @@ extern char **environ; · 92 unmodified lines | |||
| 93 | #define ML(d) extern value ml_##d; value ml_##d | 93 | #define ML(d) extern value ml_##d; value ml_##d |
| 94 | #define ML0(d) extern void ml_##d; void ml_##d | 94 | #define ML0(d) extern void ml_##d; void ml_##d |
| 95 | 95 | ||
| 96 | #define STTI(st) ((unsigned int) st) | ||
| 97 | |||
| 96 | struct slice { | 98 | struct slice { |
| 97 | int h; | 99 | int h; |
| 98 | int texindex; | 100 | int texindex; |
| @@ -1993,8 +1995,8 @@ static void ensureslinks (struct page *page) · 1894 unmodified lines | |||
| 1993 | } | 1995 | } |
| 1994 | 1996 | ||
| 1995 | static void highlightslinks (struct page *page, int xoff, int yoff, | 1997 | static void highlightslinks (struct page *page, int xoff, int yoff, |
| 1996 | int noff, const char *targ, mlsize_t tlen, | 1998 | int noff, const char *targ, unsigned int tlen, |
| 1997 | const char *chars, mlsize_t clen, int hfsize) | 1999 | const char *chars, unsigned int clen, int hfsize) |
| 1998 | { | 2000 | { |
| 1999 | char buf[40]; | 2001 | char buf[40]; |
| 2000 | struct slink *slink; | 2002 | struct slink *slink; |
| @@ -2241,8 +2243,8 @@ ML (postprocess (value ptr_v, value hlinks_v, · 240 unmodified lines | |||
| 2241 | ensureannots (page); | 2243 | ensureannots (page); |
| 2242 | if (hlmask & 1) highlightlinks (page, xoff, yoff); | 2244 | if (hlmask & 1) highlightlinks (page, xoff, yoff); |
| 2243 | if (hlmask & 2) { | 2245 | if (hlmask & 2) { |
| 2244 | highlightslinks (page, xoff, yoff, noff, targ, tlen, | 2246 | highlightslinks (page, xoff, yoff, noff, targ, STTI (tlen), |
| 2245 | chars, clen, hfsize); | 2247 | chars, STTI (clen), hfsize); |
| 2246 | noff = page->slinkcount; | 2248 | noff = page->slinkcount; |
| 2247 | } | 2249 | } |
| 2248 | if (page->tgen == state.gen) { | 2250 | if (page->tgen == state.gen) { |
| @@ -2570,7 +2572,7 @@ ML (getlinkn (value ptr_v, value c_v, value n_v)) · 321 unmodified lines | |||
| 2570 | 2572 | ||
| 2571 | ret_v = Val_int (-1); | 2573 | ret_v = Val_int (-1); |
| 2572 | for (int i = 0; i < page->slinkcount; ++i) { | 2574 | for (int i = 0; i < page->slinkcount; ++i) { |
| 2573 | fmt_linkn (buf, c, clen, i); | 2575 | fmt_linkn (buf, c, STTI (clen), i); |
| 2574 | if (!strncmp (buf, n, clen)) { | 2576 | if (!strncmp (buf, n, clen)) { |
| 2575 | ret_v = Val_int (i); | 2577 | ret_v = Val_int (i); |
| 2576 | break; | 2578 | break; |