[Top][All Lists]

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

Re: finding the hork point in ~/.emacs

From: Eric Abrahamsen
Subject: Re: finding the hork point in ~/.emacs
Date: Wed, 26 Aug 2020 17:46:41 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

ken <> writes:

> On 8/26/20 4:52 PM, Emanuel Berg via Users list for the GNU Emacs text
> editor wrote:
>> ken wrote:
>>> In another thread I spoke too soon about my
>>> ~/.emacs fully working.  A lot of it isn't being
>>> executed.  This, to my understanding, means that
>>> some code is no longer working (since my recent
>>> emacs upgrade).  Is there some really good method
>>> or log file or something else which would help
>>> finding where the hork point is?
>> You can do the so-called binary search, which is
>> a fancy name for this method
>>   code_1
>>   code_2
>>   code_n
>>   code_m
>> then do
>>   code_1
>>   code_2
>>   ;; code_n
>>   ;; code_m
>> if it still doesn't work, problem is in 1 or 2, so
>>   code_1
>>   ;; code_2
>>   ;; code_n
>>   ;; code_m
>> if it ... etc
> Yes, good.  I know that technique, and I think it's better known as,
> "isolating the problem."

No, it's definitely known as binary search, because it's a more specific
technique than just commenting out random stuff and hoping. You comment
half the file, see if the problem persists. Whether it does or not,
you're now able to comment three quarters of the file, then seven
eighths, and by this point you've usually found it. No matter how big
the file, it's relatively few steps to find the problem.

reply via email to

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