Compile warnings when DEBUG symbol is defined
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pcb |
Fix Released
|
Medium
|
Unassigned |
Bug Description
When the DEBUG symbol is defined, there are a whole bunch of compile warnings. See below:
action.c: In function 'ActionElementL
action.c:7189:7: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-
int er, pr, i;
^~~
action.c: In function 'tempfile_unlink':
action.c:7492:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-
int e, rc2 = 0;
^~~
copy.c: In function 'CopyElement':
copy.c:295:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-
ElementType *element = CopyElementLowLevel (PCB->Data, Element,
^~~~~~~~~~~
edif.y:3916:8: warning: return type defaults to 'int' [-Wimplicit-int]
static Stack(char * str, int typ)
^~~~~
edif.y:3932:8: warning: return type defaults to 'int' [-Wimplicit-int]
static DumpStack()
^~~~~~~~~
edif.y: In function 'DumpStack':
edif.y:3950:7: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
if (cxt = FindContext(
^~
edif.y:3952:7: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
else if (tok = FindToken(
^~~~
edif.y: In function 'Stack':
edif.y:3926:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
edif.y: In function 'DumpStack':
edif.y:3968:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
Changed in pcb: | |
status: | New → In Progress |
Changed in pcb: | |
milestone: | none → pcb-4.0.1 |
importance: | Undecided → Medium |
Changed in pcb: | |
milestone: | pcb-4.0.1 → pcb-4.1.0 |
Changed in pcb: | |
milestone: | pcb-4.1.0 → pcb-4.0.1 |
Changed in pcb: | |
status: | Fix Committed → Fix Released |
I pushed a branch to fix these, home/cparker/ LP16559061.
This branch is a follow on to home/cparker/ LP1659045 and the related bug https:/ /bugs.launchpad .net/pcb/ +bug/1659045.