Warning for 4 unused variables in scriptfile.c in Tiny and Small (only) after applying patches 8.1. 56 to 58

9 views
Skip to first unread message

Tony Mechelynck

unread,
Dec 29, 2019, 7:25:21 PM12/29/19
to Bram Moolenaar, vim_dev
This is probably no problem, but…

gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -fno-strength-reduce -Wall
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -o objects/scriptfile.o
scriptfile.c
scriptfile.c: In function ‘estack_sfile’:
scriptfile.c:102:10: warning: unused variable ‘done’ [-Wunused-variable]
int done;
^~~~
scriptfile.c:101:11: warning: unused variable ‘res’ [-Wunused-variable]
char *res;
^~~
scriptfile.c:99:10: warning: unused variable ‘idx’ [-Wunused-variable]
int idx;
^~~
scriptfile.c:98:10: warning: unused variable ‘len’ [-Wunused-variable]
int len;
^~~


Using gcc 7.4.1 on openSUSE Linux Leap 15.1

Best regards,
Tony.

Bram Moolenaar

unread,
Dec 30, 2019, 6:18:01 AM12/30/19
to vim...@googlegroups.com, Tony Mechelynck

Tony wrote:

> This is probably no problem, but…

We like to keep the build warning-free!
I'll add an #ifdef.

--
f y cn rd ths thn y cn hv grt jb n cmptr prgrmmng

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Reply all
Reply to author
Forward
0 new messages