On 01-Dec-2022 05:12, Bram Moolenaar wrote:
Patch 9.0.0977
Problem:    It is not easy to see what client-server commands are doing.
Solution:   Add channel log messages if ch_log() is available.  Move the
             channel logging and make it available with the +eval feature.
Files:      Filelist, runtime/doc/starting.txt, src/if_xcmdsrv.c,
             src/clientserver.c, src/logfile.c, src/proto/logfile.pro,
             src/proto.h, src/channel.c, src/proto/channel.pro, src/evalfunc.c,
             src/gui_gtk_x11.c, src/main.c, src/message.c, src/os_unix.c,
             src/os_win32.c, src/regexp_bt.c, src/regexp_nfa.c, src/term.c,
             src/time.c, src/ui.c, src/globals.h, src/Makefile,
             src/Make_ami.mak, src/Make_mvc.mak, src/Make_vms.mms,
             src/Make_cyg_ming.mak


After this patch mingw64 (clang 15.0.5) gives these errors/warnings. I have FEAT_JOB_CHANNEL disabled for this build so I reckon it has something to do with that.
<snip>
clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD logfile.c -o gobjx
86-64/logfile.o
logfile.c:35:6: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
            ch_log(NULL, "closing this logfile, opening %s", fname);
            ^
logfile.c:44:5: error: use of undeclared identifier 'ch_log_output'
    ch_log_output = vim_strchr(opt, 'o') != NULL ? LOG_ALWAYS : FALSE;
    ^
logfile.c:105:1: error: conflicting types for 'ch_log'
ch_log(channel_T *ch, const char *fmt, ...)
^
logfile.c:35:6: note: previous implicit declaration is here
            ch_log(NULL, "closing this logfile, opening %s", fname);
            ^
logfile.c:118:5: error: use of undeclared identifier 'did_repeated_msg'
    did_repeated_msg = 0;
    ^
logfile.c:135:5: error: use of undeclared identifier 'did_repeated_msg'
    did_repeated_msg = 0;
    ^
1 warning and 4 errors generated.
</snip>

<snip>
clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD main.c -o gobjx86-64/main.o main.c:1091:2: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
        ch_log(NULL, is_safe ? "SafeState: Start triggering"
        ^
main.c:1109:2: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
        ch_log(NULL, "SafeState: reset: %s", reason);
        ^
main.c:1567:5: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    ch_log(NULL, "Exiting...");
    ^
3 warnings generated.
</snip>

<snip>
clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD message.c -o gobjx86-64/message.o
message.c:165:9: error: use of undeclared identifier 'emsg_to_channel_log'
    if (emsg_to_channel_log)
        ^
message.c:167:2: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
        ch_log(NULL, "ERROR: %s", s);
        ^
message.c:729:6: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
            ch_log(NULL, "ERROR silent: %s", (char *)s);
            ^
2 warnings and 1 error generated.
</snip>

<snip>
clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD os_win32.c -o gobjx86-64/os_win32.o os_win32.c:4927:5: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    ch_log(NULL, "executing shell command: %s", cmd);
    ^
1 warning generated.
</snip>

clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD term.c -o gobjx86-64/term.o term.c:2645:6: error: use of undeclared identifier 'ch_log_output'; did you mean 'ch_log_active'?
        if (ch_log_output != FALSE)
            ^~~~~~~~~~~~~
            ch_log_active
proto/logfile.pro:3:5: note: 'ch_log_active' declared here
int ch_log_active(void);
    ^
term.c:2648:6: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
            ch_log(NULL, "raw %s output: \"%s\"",
            ^
term.c:2654:10: error: use of undeclared identifier 'ch_log_output'; did you mean 'ch_log_active'?
            if (ch_log_output == TRUE)
                ^~~~~~~~~~~~~
                ch_log_active
proto/logfile.pro:3:5: note: 'ch_log_active' declared here
int ch_log_active(void);
    ^
term.c:2655:3: error: use of undeclared identifier 'ch_log_output'
                ch_log_output = FALSE;  // only log once
                ^
1 warning and 3 errors generated.
</snip>

<snip>
clang -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603 -DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO -pipe -Wall -O3 -fomit-frame-pointer -fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD ui.c -o gobjx86-64/ui.o ui.c:541:5: warning: call to undeclared function 'ch_log'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    ch_log(NULL, "ui_delay(%ld)", msec);
    ^
1 warning generated.
</snip>

Sorry I don't have any patches for this.
Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/35cfb7a6-f0b8-1290-b585-d42ac45afc23%40internode.on.net.

Raspunde prin e-mail lui