Skip to content
Tcl Source Code View Ticket
Login

View Ticket

warning: variable set but not used [-Wunused-but-set-variable]

Closed / Fixed54a305cb88d1ab69c4295ca9809c91d402f58c1aCreated 3 years agoUpdated 3 years ago
Descriptionwiki2023-11-08 20:57:37
When building core-8-6-branch (here, on macOS with --disable-aqua):
/Volumes/Users/fvogel/Documents/tcltk/fossil/tcl/generic/tclDate.c:1299:9: warning: variable 'TclDatenerrs' set but not used [-Wunused-but-set-variable]
    int yynerrs;
        ^
/Volumes/Users/fvogel/Documents/tcltk/fossil/tcl/generic/tclDate.c:67:25: note: expanded from macro 'yynerrs'
#define yynerrs         TclDatenerrs
                        ^

and:

/Volumes/Users/fvogel/Documents/tcltk/fossil/tcl/generic/tclFileName.c:2141:29: warning: variable 'count' set but not used [-Wunused-but-set-variable]
    int baseLength, quoted, count;
                            ^
Referenced by3
fvogel Ticket [54a305cb88]: 3 changes [History diff]2023-11-08 20:58:38
jan.nijtmanswiki2023-11-10 13:20:31

Second warning fixed [here]

The warning in tclDate.c is more complicated: this is generated code. Maybe upgrade to a later version of Bison?

jan.nijtmanswiki2023-11-10 14:31:32

Second part fixed [here]. I tried bison 3.8.2, but that didn't resolve this problem. So, for now, manually edited.

I like being able to release Tcl 8.6.14 warning-free ;-)

Log in (anonymous is fine) to add a comment.