mirror of
https://github.com/frida/tinycc
synced 2024-11-27 18:19:35 +03:00
Give clang one less thing to complain about
"s"[i<2] and "s" + (i<2) are literally identical, but the latter triggers a warning from clang because it looks so much like a noob is trying to concatenate an integer and a string. The former is arguably more clear.
This commit is contained in:
parent
dfb75d9b6c
commit
3c0a73822d
2
tccpe.c
2
tccpe.c
@ -965,7 +965,7 @@ static void pe_build_exports(struct pe_info *pe)
|
||||
} else {
|
||||
fprintf(op, "LIBRARY %s\n\nEXPORTS\n", dllname);
|
||||
if (pe->s1->verbose)
|
||||
printf("<- %s (%d symbol%s)\n", buf, sym_count, "s" + (sym_count < 2));
|
||||
printf("<- %s (%d symbol%s)\n", buf, sym_count, "s"[sym_count < 2]);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -390,7 +390,7 @@ usage:
|
||||
}
|
||||
|
||||
if (v)
|
||||
printf("<- %s (%d symbol%s)\n", outfile, i, "s" + (i<2));
|
||||
printf("<- %s (%d symbol%s)\n", outfile, i, "s"[i<2]);
|
||||
|
||||
ret = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user