To: vim-dev@vim.org Subject: Patch 6.1.337 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.1.337 Problem: When using "finish" in debug mode in function B() for ":call A(B())" does not stop after B() is finished. Solution: Increase debug_level while evaluating a function. Files: src/ex_docmd.c *** ../vim61.336/src/ex_docmd.c Sun Feb 16 22:08:10 2003 --- src/ex_docmd.c Sun Feb 16 22:07:15 2003 *************** *** 609,614 **** --- 609,618 ---- cstack.cs_had_endwhile = FALSE; cstack.cs_had_continue = FALSE; ga_init2(&lines_ga, (int)sizeof(wcmd_T), 10); + + /* Inside a function use a higher debug level. */ + if (getline == get_func_line) + ++debug_level; #endif /* *************** *** 913,918 **** --- 917,925 ---- EMSG(_("E171: Missing :endif")); } + /* When leaving a function, reduce debug level. */ + if (getline == get_func_line) + --debug_level; /* * Go to debug mode when returning from a function in which we are * single-stepping. *** ../vim61.336/src/version.c Sun Feb 16 22:47:47 2003 --- src/version.c Sun Feb 16 22:48:58 2003 *************** *** 608,609 **** --- 612,615 ---- { /* Add new patch number below this line */ + /**/ + 337, /**/ -- In war we're tough and able. Quite indefatigable Between our quests We sequin vests And impersonate Clark Gable It's a busy life in Camelot. I have to push the pram a lot. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\ \\\ Project leader for A-A-P -- http://www.A-A-P.org /// \\\ Help AIDS victims, buy at Amazon -- http://ICCF.nl/click1.html ///