Support whitespace in default value for change signature refactoring

This commit is contained in:
Mathias Fussenegger 2023-11-28 18:46:01 +01:00 committed by Mathias Fußenegger
parent 44403b2ef6
commit 66b5ace68a

View file

@ -493,7 +493,7 @@ local function change_signature(bufnr, command, code_action_params)
type = matches[3],
})
else
matches = { line:match("%- (%w+) ([^ ]+) ?(%w*)") }
matches = { line:match("%- (%w+) ([^ ]+) ?(.*)") }
if next(matches) then
table.insert(parameters, {
type = matches[1],