GNU bug report logs -
#25219
26.0.50; ispell failing
Previous Next
Full log
Message #16 received at 25219-done <at> debbugs.gnu.org (full text, mbox):
On Sun, Dec 18, 2016 at 05:18:15PM +0200, Eli Zaretskii wrote:
> > From: Alan Third <alan <at> idiocy.org>
> > Date: Sun, 18 Dec 2016 11:51:37 +0000
> > Cc: 25219 <at> debbugs.gnu.org
> >
> > > run M-x ispell-buffer
> > >
> > > watch it fail on fist word not in dictionry
> > >
> > > I use ispell before sending mail (dyslexia and sspect keyboad)
> > >
> > > een this way fo a week or so
> >
> > It looks like this started with commit:
> >
> > db6e1f82976a7f232a4a206a3c850ed34cfbfdd3
> >
> > The following patch appears to fix the problem for me, but I have my
> > doubts it's the best way to handle it and I've only tested with
> > hunspell.
> >
> > modified lisp/textmodes/ispell.el
> > @@ -3338,7 +3338,7 @@ ispell-process-line
> > ;; Markers can move with highlighting! This destroys
> > ;; end of region markers line-end and ispell-region-end
> > (let ((word-start
> > - (copy-marker (+ ispell-start (car (cdr poss)))))
> > + (copy-marker (+ ispell-start -1 (car (cdr poss)))))
> > (word-len (length (car poss)))
> > (line-end (copy-marker ispell-end))
> > (line-start (copy-marker ispell-start))
> >
> > Any thoughts?
>
> We definitely need to keep the -1 offset there. (It was previously
> supplied by ispell-offset, but that variable was deleted.) The reason
> for the offset is that the line we send to the speller has a "^"
> prepended to it (see the documentation of the Ispell interface for the
> reason why).
>
> Please add a comment to that effect when you commit the above.
Done.
Thanks!
--
Alan Third
This bug report was last modified 8 years and 207 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.