mirror of
https://github.com/vim/vim.git
synced 2025-10-05 05:34:07 -04:00
patch 8.2.2506: Vim9: :continue does not work correctly in a :try block
Problem: Vim9: :continue does not work correctly in a :try block Solution: Add the TRYCLEANUP instruction. (closes #7827)
This commit is contained in:
10
src/vim9.h
10
src/vim9.h
@@ -100,6 +100,7 @@ typedef enum {
|
||||
ISN_PUSHEXC, // push v:exception
|
||||
ISN_CATCH, // drop v:exception
|
||||
ISN_ENDTRY, // take entry off from ec_trystack
|
||||
ISN_TRYCONT, // handle :continue inside a :try statement
|
||||
|
||||
// more expression operations
|
||||
ISN_ADDLIST, // add two lists
|
||||
@@ -209,9 +210,15 @@ typedef struct {
|
||||
// arguments to ISN_TRY
|
||||
typedef struct {
|
||||
int try_catch; // position to jump to on throw
|
||||
int try_finally; // position to jump to for return
|
||||
int try_finally; // :finally or :endtry position to jump to
|
||||
} try_T;
|
||||
|
||||
// arguments to ISN_TRYCONT
|
||||
typedef struct {
|
||||
int tct_levels; // number of nested try statements
|
||||
int tct_where; // position to jump to, WHILE or FOR
|
||||
} trycont_T;
|
||||
|
||||
// arguments to ISN_ECHO
|
||||
typedef struct {
|
||||
int echo_with_white; // :echo instead of :echon
|
||||
@@ -333,6 +340,7 @@ struct isn_S {
|
||||
jump_T jump;
|
||||
forloop_T forloop;
|
||||
try_T try;
|
||||
trycont_T trycont;
|
||||
cbfunc_T bfunc;
|
||||
cdfunc_T dfunc;
|
||||
cpfunc_T pfunc;
|
||||
|
Reference in New Issue
Block a user