mirror of
https://github.com/vim/vim.git
synced 2025-10-03 05:14:07 -04:00
patch 8.2.1322: Vim9: method on double quoted string doesn't work
Problem: Vim9: method on double quoted string doesn't work. Solution: Recognize double quoted string. (closes #6562)
This commit is contained in:
@@ -502,8 +502,11 @@ def Test_vim9script_call()
|
||||
assert_equal('some', var)
|
||||
|
||||
# line starting with single quote is not a mark
|
||||
# line starting with double quote can be a method call
|
||||
'asdfasdf'->MyFunc()
|
||||
assert_equal('asdfasdf', var)
|
||||
"xyz"->MyFunc()
|
||||
assert_equal('xyz', var)
|
||||
|
||||
def UseString()
|
||||
'xyork'->MyFunc()
|
||||
@@ -511,6 +514,12 @@ def Test_vim9script_call()
|
||||
UseString()
|
||||
assert_equal('xyork', var)
|
||||
|
||||
def UseString2()
|
||||
"knife"->MyFunc()
|
||||
enddef
|
||||
UseString2()
|
||||
assert_equal('knife', var)
|
||||
|
||||
# prepending a colon makes it a mark
|
||||
new
|
||||
setline(1, ['aaa', 'bbb', 'ccc'])
|
||||
|
Reference in New Issue
Block a user