diff options
Diffstat (limited to 'src/vim9expr.c')
-rw-r--r-- | src/vim9expr.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vim9expr.c b/src/vim9expr.c index 85eb7afb90..41ed7e7401 100644 --- a/src/vim9expr.c +++ b/src/vim9expr.c @@ -379,6 +379,8 @@ compile_class_object_index(cctx_T *cctx, char_u **arg, type_T *type) } if (type->tt_type == VAR_CLASS) { + // Remove the class type from the stack + --cctx->ctx_type_stack.ga_len; if (generate_CLASSMEMBER(cctx, TRUE, cl, m_idx) == FAIL) return FAIL; } @@ -475,6 +477,8 @@ compile_class_object_index(cctx_T *cctx, char_u **arg, type_T *type) } *arg = name_end; + // Remove the class type from the stack + --cctx->ctx_type_stack.ga_len; return generate_CLASSMEMBER(cctx, TRUE, cl, idx); } |