[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: indent-tabs-mode in dir-locals

From: Stefan Monnier
Subject: Re: indent-tabs-mode in dir-locals
Date: Tue, 06 Jan 2009 23:13:49 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

> (defun indent-tabs-mode-maybe ()
>   (if (and (null indent-tabs-mode)
>            ;; Trust the major mode.
>            (not (local-variable-p 'indent-tabs-mode))
>            (save-excursion
>              (goto-char (point-min))
>              ;; If there are at least 10 lines with a leading TAB, use TABs.
>              (re-search-forward "^    " (+ (point) 100000) t 10)))
>       (set (make-local-variable 'indent-tabs-mode) t)))

I don't think such complexity is warranted for such a minor problem.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]