This will allow for the following:
if want_foo; then
function foobar() {
echo "foo"
}
else
function foobar() {
echo "bar"
}
fi
foobar
Signed-off-by: TerraTech <1118433+TerraTech@users.noreply.github.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
(file_progress_show_deleting): reduce update rate of delete status
window. Use the way as in c31e413b2a.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
How to reproduce the bug:
* compile mc with gpm support
* run the gpm daemon on the console
* login to the machine with ssh from console on another machine
* run mc
At this situation, keyboard response will be sluggish and mc will consume
CPU time when idle. The reason is that mc is trying to reopen the Gpm
connection over and over again and gpm will try to close the connection
over and over again (because the user is not on the local console).
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
To reproduce, open this .c file in mcedit (remove backslashes):
/* this preprocessor macro is not colorized,
when there is whitespace before '#' and the next line is not empty */
\ #if not_colorized
int code;
/* this preprocessor macro is colorized properly, the next line is empty */
\ #if colorized
int code2;
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
...when both context and keyword end with a newline.
To reproduce, create .c or .cxx file and open it in mcedit:
\#endif // preprocessor macro with one-line comment
int code; /* <-- this line is colorized incorrectly */
int code2; /* <-- next line is colorized properly */
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* 3955_cleanup: (50 commits)
(mc_AC_GET_FS_INFO): rename to mc_GET_FS_INFO...
Sync with gnulib 5d6ca1aeeb04b9b0cd760529d548ac26675ef9b9.
configure.c: fix AX_GCC_FUNC_ATTRIBUTE detection on custom CFLAGS
(panel_new_with_dir): variable 'err' is assigned a value that is never used.
(load_setup): reduce variable scope.
(mcview_display_hex): reduce variable scope.
(check_hardlinks): suspicious condition (assignment + comparison).
src/filemanager/filegui.c: fix coding style.
File operations: rename variables.
Clarify checks of dialog and widget existence.
Sync with gnulib a3d1c7849936e481ae10dea5312a36a448a5d5bf.
Sync with gnulib 248cb6a2499ffa5a9e652d05e61c4a959fbae605.
VFS GC: use mc_timer.
VFS GC: reimplement using GSList.
vfs_stamping: make opaque.
src/filemanager/treestore.c: fix coding style, minor refactoring.
src/filemanager/tree.c: fix coding style, minor refactoring.
WTree: use gboolean type for boolean members.
(find_do_view_edit): Remove unused variable. Found by PVS-Studio:V575
(smbfs_fake_share_stat): Remove unneeded g_free(NULL) (PVS-Studio:V575)
...
AX_GCC_FUNC_ATTRIBUTE detect attribute feature by compiler warnings.
Custom or unrecognized CFLAGS can causes extra warnings so attribute
check failed.
Reset CFLAGS and restore after AX_GCC_FUNC_ATTRIBUTE call.
Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Clarify expression with parentheses.
Found by cppcheck 1.81.
Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Widget list in the dialog cannot contain empty elements.
Dialog list cannot contain empty elements too.
Therefore simplify some checks.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>