From 78990df4f114c45adc7fd2678ffaedf0c4124d95 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Mon, 29 Apr 2013 16:13:59 -0400 Subject: More code cleanup. "local buffer = buffer" and similar optimizations are not needed since lexing the buffer is much more expensive and reaction time is limited by how fast the keyboard can submit key presses. --- modules/textadept/bookmarks.lua | 2 -- 1 file changed, 2 deletions(-) (limited to 'modules/textadept/bookmarks.lua') diff --git a/modules/textadept/bookmarks.lua b/modules/textadept/bookmarks.lua index 449626d7..3f383a56 100644 --- a/modules/textadept/bookmarks.lua +++ b/modules/textadept/bookmarks.lua @@ -20,7 +20,6 @@ local MARK_BOOKMARK = _SCINTILLA.next_marker_number() -- current line. The default value is `nil`, toggling a bookmark. -- @name toggle function M.toggle(on) - local buffer = buffer local line = buffer:line_from_position(buffer.current_pos) local f = on and buffer.marker_add or buffer.marker_delete if on == nil then -- toggle @@ -45,7 +44,6 @@ end -- @param start `0` when going to the next mark, `buffer.line_count` when going -- to the previous mark. local function goto_mark(f, increment, wrap_start) - local buffer = buffer local current_line = buffer:line_from_position(buffer.current_pos) local line = f(buffer, current_line + increment, 2^MARK_BOOKMARK) if line == -1 then line = f(buffer, wrap_start, 2^MARK_BOOKMARK) end -- cgit v1.2.3