Subject: bug#9560: An exact recipe

From: Michael Welsh Duggan <[email-masked]>
Date: Thu, 20 Oct 2011 21:42:30 -0400

Alan Mackenzie <[email-masked]> writes:

> Hi, Michael.
>
> On Wed, Oct 19, 2011 at 09:45:45AM -0400, Michael Welsh Duggan wrote:
>> Alan Mackenzie <[email-masked]> writes:
>
>> Okay, I've done some experimenting, and unfortunately, I have been
>> unable to recreate this problem using this recipe using emacs -Q -nw.
>> I've only encountered it using an X window.
>
> That still perplexes me.  I've got a fix, but the problem should have
> appeared on a tty and a -nw too.

Indeed.  Could font-locking interfere at any point?

>> In this environment, I was able to recreate the problem consistently.
>> I was able to replace the initial "3*C-v 7*C-n" in the macro with
>> "100*C-n C-l" and this allowed it to work with larger frame sizes.
>> Don't ask me why the C-l is necessary, as I do not know.
>
>> >> When you have solved this bug, please let me know if the solution has a
>> >> reasonable chance of having solved the other problem that I have not
>> >> been able to recreate reliably, which is getting "topmost-intro indent
>> >> 0" instead of "statement indent 4" when in the middle of editing a
>> >> function.  If these have little chance of being connected, I'll do my
>> >> best to try to create that scenario again (no promises).
>
> I think there's a good chance of that bug being fixed by the following
> patch (no promises ;-).

We can always hope!

> The bug was a bit of carelessness on my part.  I'd done
>   (unless (and T1 T2 T3) ...) 
> , and in the body tested
>   (and T1 (not T3))
> , which is rubbish, since that says nothing about the state of T2.  T2
> being the wrong way round was what caused the bug to show up.
>
> Anyhow, here's the patch.  Only the first chunk is for the bug; the rest
> of it is the superior instrumentation.  Let me know how this goes!

Well, it certainly fixes things in my initial tests.  After checking in,
I would consider this bug closed.  I'll open up a new one if I notice
something weird in the future.

-- 
Michael Welsh Duggan
([email-masked])