diff --git a/Changes b/Changes index a3b2087..0cef2b8 100644 --- a/Changes +++ b/Changes @@ -26,6 +26,9 @@ Release ... * When moving up or down to a row with different column arrangement while the cursor is positioned over a multicolumn character, the leftmost character above the original position is chosen in the new row. +* If both the '-t' and the '-c' option are given, the '-t' option is now + processed first, i.e. the command is executed at the position where the + tag was found. Release 1/19/05 * The last release erroneously made 'X' work like 'x' in visual mode. It now diff --git a/ex_cmdsub.c b/ex_cmdsub.c index c47b357..aa94e0e 100644 --- a/ex_cmdsub.c +++ b/ex_cmdsub.c @@ -73,7 +73,7 @@ #ifndef lint #ifdef DOSCCS -static char sccsid[] = "@(#)ex_cmdsub.c 1.26 (gritter) 12/1/04"; +static char sccsid[] = "@(#)ex_cmdsub.c 1.27 (gritter) 2/17/05"; #endif #endif @@ -560,6 +560,7 @@ tagfind(bool quick) int owrapscan; char *fn, *fne; struct stat sbuf; + char *savefirstpat = NULL; #ifdef FASTTAG int ft_iof; char ft_iofbuf[MAXBSIZE]; @@ -711,6 +712,8 @@ badtags: if (strcmp(filebuf, savedfile) || !edited) { char cmdbuf2[sizeof filebuf + 10]; + savefirstpat = firstpat; + firstpat = NULL; /* Different file. Do autowrite & get it. */ if (!quick) { ckaw(); @@ -730,6 +733,7 @@ badtags: if (tflag) value(WRAPSCAN) = owrapscan; samef = 0; + firstpat = savefirstpat; } /* @@ -753,6 +757,8 @@ badtags: value(MAGIC) = omagic; if (tflag) { value(WRAPSCAN) = owrapscan; + if (savefirstpat) + globp = savefirstpat; tflag = 0; } return; diff --git a/ex_version.c b/ex_version.c index 9b58336..50e30cb 100644 --- a/ex_version.c +++ b/ex_version.c @@ -70,12 +70,12 @@ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * Sccsid @(#)ex_version.c 1.124 (gritter) 2/15/05 + * Sccsid @(#)ex_version.c 1.125 (gritter) 2/17/05 */ #include "ex.h" -static char *versionstring = "@(#)Version 4.0 (gritter) 2/15/05"; +static char *versionstring = "@(#)Version 4.0 (gritter) 2/17/05"; void printver(void)