From: Karl Heuer Date: Sat, 30 May 1998 14:29:25 +0000 (+0000) Subject: (viper-skip-syntax): Bug fix for eob/bob cases. X-Git-Tag: emacs-20.3~793 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=63b98362a903e7a25363753cf1349d30fc13a791;p=emacs.git (viper-skip-syntax): Bug fix for eob/bob cases. --- diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index 6cad4511d28..111edd10b6a 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el @@ -1295,7 +1295,10 @@ This option is appropriate if you like Emacs-style words." (t nil))) (if (memq ?^ syntax) (setq negated-syntax t)) - (while (and (not (= local 0)) (not (eobp))) + (while (and (not (= local 0)) + (cond ((eq direction 'forward) + (not (eobp))) + (t (not (bobp))))) (setq char-looked-at (viper-char-at-pos direction) ;; if outside the range, set to nil syntax-of-char-looked-at (if char-looked-at