File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -194,7 +194,7 @@ def writelines(self, seq):
194194
195195
196196def num_to_str (obj ):
197- if isinstance (obj , num_types ):
197+ if isinstance (obj , num_types ) and not isinstance ( obj , bool ) :
198198 return str (obj )
199199 else :
200200 return obj
Original file line number Diff line number Diff line change @@ -28,3 +28,10 @@ def test_host_async_error(vim):
2828 assert event [1 ] == 'nvim_error_event'
2929 assert 'rplugin-host: Async request caused an error:\n boom\n ' \
3030 in h ._on_error_event (None , 'boom' )
31+
32+ def test_legacy_vim_eval (vim ):
33+ h = ScriptHost (vim )
34+ assert h .legacy_vim .eval ('1' ) == '1'
35+ assert h .legacy_vim .eval ('v:null' ) == None
36+ assert h .legacy_vim .eval ('v:true' ) == True
37+ assert h .legacy_vim .eval ('v:false' ) == False
You can’t perform that action at this time.
0 commit comments