ref: 57a2c3cbf63910b988ef0144e24062bfad269655
parent: 559b623fee508a294ed507a9c2cbb01cb5f7f7c3
author: aiju <devnull@localhost>
date: Sun Dec 2 06:36:58 EST 2018
kencc: make "function not declared" a warning unless compiling with -T
--- a/sys/src/cmd/cc/com.c
+++ b/sys/src/cmd/cc/com.c
@@ -608,9 +608,11 @@
goto bad;
n->type = l->type->link;
if(!debug['B']){- if(l->type->down == T)
+ if(l->type->down == T){+ if(!debug['T'])
+ nerrors--;
diag(n, "function not declared: %F", l);
- else if(l->type->down->etype == TOLD) {+ }else if(l->type->down->etype == TOLD) {nerrors--;
diag(n, "function args not checked: %F", l);
}
--
⑨