From 53d3f8f64b2e158c174addda1c4f022c671e1881 Mon Sep 17 00:00:00 2001 From: Ben Jackson Date: Sun, 4 Aug 2019 19:37:23 +0100 Subject: [PATCH] Fix inputrestore --- python3/vimspector/utils.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/python3/vimspector/utils.py b/python3/vimspector/utils.py index 796aa21..9c56e8b 100644 --- a/python3/vimspector/utils.py +++ b/python3/vimspector/utils.py @@ -242,7 +242,7 @@ def InputSave(): vim.eval( 'inputsave()' ) try: yield - except Exception: + finally: vim.eval( 'inputrestore()' ) @@ -262,7 +262,6 @@ def SelectFromList( prompt, options ): def AskForInput( prompt ): - # TODO: Handle the ctrl-c and such responses returning empty or something with InputSave(): try: return vim.eval( "input( '{0}' )".format( Escape( prompt ) ) )