@@ -15,7 +15,7 @@ local default_display_counter = function()
15
15
end
16
16
17
17
--- @return string
18
- local debuginfo_tag_and_counter = function ()
18
+ local get_debugline_tag_and_counter = function ()
19
19
local tag_and_counter = " "
20
20
21
21
if global_opts .print_tag then
34
34
35
35
--- @param opts DebugprintFunctionOptionsInternal
36
36
--- @return string
37
- local debuginfo = function (opts )
37
+ local get_debugline_textcontent = function (opts )
38
38
local current_line_nr = vim .api .nvim_win_get_cursor (0 )[1 ]
39
39
40
40
local line_components = {}
@@ -49,7 +49,7 @@ local debuginfo = function(opts)
49
49
force_snippet_for_plain = true
50
50
end
51
51
52
- local tag_and_counter = debuginfo_tag_and_counter ()
52
+ local tag_and_counter = get_debugline_tag_and_counter ()
53
53
54
54
if tag_and_counter ~= " " then
55
55
table.insert (line_components , tag_and_counter .. " :" )
@@ -115,21 +115,23 @@ local construct_debugprint_line = function(opts, fileconfig)
115
115
end
116
116
117
117
line_to_insert = left
118
- .. debuginfo (opts )
118
+ .. get_debugline_textcontent (opts )
119
119
.. fileconfig .mid_var
120
120
.. opts .variable_name
121
121
.. fileconfig .right_var
122
122
else
123
123
opts .variable_name = nil
124
- line_to_insert = fileconfig .left .. debuginfo (opts ) .. fileconfig .right
124
+ line_to_insert = fileconfig .left
125
+ .. get_debugline_textcontent (opts )
126
+ .. fileconfig .right
125
127
end
126
128
127
129
return line_to_insert
128
130
end
129
131
130
132
--- @param opts DebugprintFunctionOptionsInternal
131
133
--- @return nil
132
- local addline = function (opts )
134
+ local insert_debugprint_line = function (opts )
133
135
local line_to_insert
134
136
135
137
local fileconfig = get_filetype_config ()
@@ -176,7 +178,7 @@ local cache_request = {}
176
178
177
179
--- @return nil
178
180
M .debugprint_operatorfunc_regular = function ()
179
- addline (cache_request )
181
+ insert_debugprint_line (cache_request )
180
182
utils_operator .set_callback (
181
183
" v:lua.require'debugprint'.debugprint_operatorfunc_regular"
182
184
)
0 commit comments