summaryrefslogtreecommitdiffstats
path: root/runtime/pack
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2021-08-14 21:25:52 +0200
committerBram Moolenaar <Bram@vim.org>2021-08-14 21:25:52 +0200
commit6aa57295cfbe8f21c15f0671e45fd53cf990d404 (patch)
tree21d5b91f8af47cf5cecea7b615cd84a65a108c30 /runtime/pack
parentbfb2bb16bc69441fa3ec13caacb2c94637a8a0ec (diff)
Update runtime files
Diffstat (limited to 'runtime/pack')
-rw-r--r--runtime/pack/dist/opt/termdebug/plugin/termdebug.vim23
1 files changed, 22 insertions, 1 deletions
diff --git a/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim b/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
index f80d9c396f..3b9002a58a 100644
--- a/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
+++ b/runtime/pack/dist/opt/termdebug/plugin/termdebug.vim
@@ -2,7 +2,7 @@
"
" Author: Bram Moolenaar
" Copyright: Vim license applies, see ":help license"
-" Last Change: 2021 May 18
+" Last Change: 2021 Aug 06
"
" WORK IN PROGRESS - Only the basics work
" Note: On MS-Windows you need a recent version of gdb. The one included with
@@ -121,6 +121,10 @@ func s:StartDebug_internal(dict)
let s:pid = 0
let s:asmwin = 0
+ if exists('#User#TermdebugStartPre')
+ doauto <nomodeline> User TermdebugStartPre
+ endif
+
" Uncomment this line to write logging in "debuglog".
" call ch_logfile('debuglog', 'w')
@@ -167,6 +171,10 @@ func s:StartDebug_internal(dict)
call win_gotoid(curwinid)
endif
endif
+
+ if exists('#User#TermdebugStartPost')
+ doauto <nomodeline> User TermdebugStartPost
+ endif
endfunc
" Use when debugger didn't start or ended.
@@ -596,7 +604,12 @@ func s:GetAsmAddr(msg)
let addr = s:DecodeMessage(substitute(a:msg, '.*addr=', '', ''))
return addr
endfunc
+
func s:EndTermDebug(job, status)
+ if exists('#User#TermdebugStopPre')
+ doauto <nomodeline> User TermdebugStopPre
+ endif
+
exe 'bwipe! ' . s:commbuf
unlet s:gdbwin
@@ -642,10 +655,18 @@ func s:EndDebugCommon()
endif
endif
+ if exists('#User#TermdebugStopPost')
+ doauto <nomodeline> User TermdebugStopPost
+ endif
+
au! TermDebug
endfunc
func s:EndPromptDebug(job, status)
+ if exists('#User#TermdebugStopPre')
+ doauto <nomodeline> User TermdebugStopPre
+ endif
+
let curwinid = win_getid(winnr())
call win_gotoid(s:gdbwin)
set nomodified