...or not-so-large but nevertheless
contain more than one function call,
or contain loops, or contain if's and at least one
function call, or contain largish objects on stack.
In my experience, in those cases the code size
growth is big enough to not inline stuff.
I guess some of the really big functions
are defined inline because they have, or had in the past,
just one callsite.
But for a few years gcc already does it automatically,
no need to do it by hand and risk code size explosion
when later during code evolution another callsite
is created. This optimization by hand is simply
no longer needed.
Anyway, here is the code size difference:
text data bss dec hex filename
572337 17944 177820 768101 bb865 mc.t5/.obj/src/mc
567697 17944 177820 763461 ba645 mc.t6/.obj/src/mc
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
first commit for support drag cursor after end of line
* change mouse movement, allow place cursor after EOL
* change vertical select
* fix: right scroll
Signed-off-by: Ilia Maslakov <il.smind@google.com>
Signed-off-by: Patrick Winnertz <winnie@debian.org>
edit: cleanup: moved variable declaration to begin of block
edit: have_charset: added explicit variable declarations
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
fix not initialized variable 'cw'
fix variables 'cw', 'utf_ch', make more safety algorithm.
All editor private API stuff is located now in edit/edit-impl.h.
Public API is located in edit/edit.h.
Added functions to read some fields of WEdit struct.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* commit 'origin/340_inrorrect_handling_of_wildcards': (21 commits)
Fixed work with copying/moving files by mask into subdirs
Fixed bug with copying files/dirs into directory with 'wild' name (such as ${}, \1, etc.)
Fixed patterns escaping of wild filenames (such as \1, ${1}, \U, etc).
Removed unused debug code from src/filegui.c
Refactoring: renamed variable 'loop' into 'curr_index'
Changed defined constants to static const char[] declarations.
Fixed declarations of functions. May be, need to split with previous commmit...
Reworked functions strutils_shell_escape and strutils_shell_unescape
Renamed functions shell_escape (to strutils_shell_escape) and shell_unescape (to strutils_shell_unescape)
Just identation of some source files
Renamed function shell_is_char_escaped to strutils_is_char_escaped; removed function mc_search_is_char_escaped
Moved 'escape' and 'unescape' strings functions from src/util.[ch] into src/strescape.[ch]
Fixed crash if replace group ${N} used into replace string
Some cosmetic optimisation for less code :)
Fixed searched token in source file mask.
Fixed NULL acertion if replacement don't correct
Handle new search replace behaviour into src/file.c. Also fixed filemask into src/filegui.c
Search Replace now handled \U,\u,\L,\l and \E modificators.
Just identation of regex.c and search.h
search engine: Added new syntax for replace tokenks.
...
The 'User Menu' entry is moved from 'File' submenu to 'Command' one.
The 'Edit editor menu file' and 'Edit syntax file' entries are moved
from main MC menu ('Command' submenu) to editor main menu ('Options'
submenu) and renamed.
src/cmd.c (check_for_default): moved to util.c and maken global.
(menu_edit_cmd): rewritten to handle MC menu files only and renamed
to edit_mc_menu_cmd.
Editor relevant routines are moved to editor code.
src/cmd.h: cleanup.
src/main.c: main menu reorganization.
src/user.h: moved editor macros to edit/edit.h.
src/util.c, src/util.h: check_for_default function from src/cmd.h.
Rewritten to use exist_file() function.
edit/editcmddef.h: added new commands:
CK_Load_Syntax_File and CK_Load_Menu_File.
edit/edit.h: editor file macros from src/user.h.
New type for file which is currently being edited.
Modified edit_load_cmd function to be more advanced.
edit/edit.c (edit_execute_cmd): handle new commands:
CK_Load_Syntax_File and CK_Load_Menu_File.
edit/editmenu.c: menu reorganization: moved two entries here from main
MC menu. Added requireq handle functions. Small optimization: removed
extra layer in menu entry handlers.
edit/editcmd.c: menu and syntax files edit is implemented.
Modified edit_load_cmd function to be more advanced.
* 351_show_number_line:
fix hotkey menu entry "Toggle li&ne state" now highlighted "n"
add call CK_Toggle_Line_State to edit menu
show line number in left part of screen (hotkey alt-n)
add option editor_line_status to ini (src/setup.c)
add action CK_Toggle_Line_State (edt/editcmddef.h)
change "print_to_widget()" to show line state, if option_line_state = 1 show line num (edit/editdraw.c)
change "edit_draw_this_line()", (set line state: line num, etc)
add const LINE_STATE_WIDTH, add options: option_line_state, option_line_state_width (edit/edit.h)
add switch on/off show line number (edit/edit.c)
add CK_Toggle_Line_State to translation table command_names (bindings name is Toggle-Line-State).
add const LINE_STATE_COLOR for draw left area bar line state
add color pair "editlinestate" for set in ini
add help for keyword "editlinestate" on "mc --help-color" (src/main.c)
* m-utf-8: (223 commits)
Fix wildcard pattern in file select and file find dialogs
Project builds with option --disable-charsets
Deleted build-glib1.sh because glib1 don't work with utf-8
fix building without --enable-charset
Total replacement to mc_search stuff in all places
Search engine: if found_len parameter NULL, then mc_search_run don't try to fill them
src/view.c: Reworked search stuff to usage src/search
refactoring: rename edit/editcmd_dialog.c:editcmd_dialog__get_search_types_list to
Search engine: development of hex search complete
Search engine: remove forgotten debug string and reindent file
Search engine:
configure.ac: if present glib-2.14 and higher, libpcre don't linked
Search engine: now used regexp external engines:
src/find.c: Fixed core dump if content search pattern no present
edit/editcmd_dialogs.c: fixed state of search type between dialog window calls
Find files: checkbox 'Regular expression' for content search now default unchecked
Find files: changes for usage of new search engine:
Fix copy of current/opposite path to command line: remove charset info from path
src/Makefile.am: add some header files to Make-tracking
Fixed editor menu reloading.
* Fix init of global variables cp_source and cp_display
* add property (mc_search_t*) search to WEdit srtucture
* start of reorganize edit/editcmd.c for new search engine
These functions fully replaced with g_strconcat ()
WARNING! This just stupid replace. Some parts of code need to usage
concat_dir_and_file() function instread of g_strconcat ()