Stefan Monnier writes: >> + (if (= (/ end-col tab-width) (/ beg-col tab-width)) >> + ;; The spacing does not straddle a TAB boundary, so we won't >> + ;; be able to use a TAB here anyway: there's nothing to do. >> + nil > >> This detects a case where no tabs can be used. >> It doesn't detect the case where tabs already ARE used. > > Those cases aren't matched by the regexp. > >> -(defvar tabify-regexp "[ \t][ \t]+" >> +(defvar tabify-regexp " [ \t]+" > >> Is that change supposed to exclude those other cases? > > Exactly. > > Stefan IIUC, your patch does work and is very much clearer than mine. However, it suffers from the same precondition on tabify-regexp, which should be described in its docstring. Thanks! -- | Michaël `Micha' Cadilhac | Si les religions etaient aussi tole- | | Epita/LRDE Promo 2007 | rantes qu'elles le pretendent, il y | | http://www.lrde.org/~cadilh_m | a longtemps qu'il n'y en aurait plus | `-- - JID: micha@amessage.be --' -- Moustic - --'