help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: removing white space highlight


From: Emanuel Berg
Subject: Re: removing white space highlight
Date: Fri, 19 Feb 2016 21:43:51 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Marcin Borkowski <mbork@mbork.pl> writes:

> Or do it automatically.

Here, we only consider serious suggestions :)

About 'binary search' being "sluggish", the algorithm
itself isn't sluggish. Actually it is great when the
outcome (the test or the search) is almost instantly
extractable from any "length" of the material, *and*
when the material is possible to divide arbitrarily.

Here, the test is the existence of unwanted behavior
and the material is Elisp code, so this is so, or
almost so, because you can't cut the code in half
entirely anywhere you want (e.g., it is not possible
in the middle of a defun), but mostly, it should be
possible to divide fairly freely as the code is
probably either written "in sequence" (e.g., as single
.emacs file) *or* if it is modular (e.g., the .emacs
file is a bunch of `loads' of other files).

Once again modular code makes life easier. Start Emacs
with '-Q', confirm the unwanted isn't there, then
bring up the "load" .emacs file:

(load-file "file.elc-1")
(load-file "file.elc-2")

         ...
         
(load-file "file.elc-n")

This makes it much easier to comment out and in code.
Either do that the binary way (for a lot of files) or
just evaluate file after file until the
problem arises.

What is "sluggish" about it is rather that you don't
even attempt to make an educated guess where the
problem is. But if you have absolutely no "education"
to your guess, isn't that the right thing to do - not
to do it?

Well, yes and no. In isolation, it makes sense not
doing something that isn't there. In the long run tho,
making educated guesses is a skill just as any I'd
say. Probably the sooner you start doing them, the
better they get.

-- 
underground experts united
http://user.it.uu.se/~embe8573




reply via email to

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