[Top][All Lists]

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

bug#24633: highlight-region func using (window-hscroll) in :align-to spe

From: Eli Zaretskii
Subject: bug#24633: highlight-region func using (window-hscroll) in :align-to spec can cause inf loop
Date: Sun, 09 Oct 2016 15:42:32 +0300

> From: address@hidden
> Cc: address@hidden
> Date: Sun, 09 Oct 2016 08:29:51 -0400
> Anyway, it doesn't seem worth going through this complexity.  I just
> wonder if there is some way to stop bad lisp code from triggering a hard
> lockup.  Can the display engine notice if it's looping and throw some
> kind of error?  Maybe unset pre-redisplay-functions?

I don't see how we could detect loops in general.  But for the
particular case of infinite hscrolling, we could perhaps count the
number of times hscroll_windows was called and returned a non-zero
value, and forcibly stop the loop after some reasonable number of

Patches welcome.  Could be a nice small project for someone who wants
to gain practice with hacking the display engine.

> >> >> According to `(elisp) Pixel Specification',
> >> >> 
> >> >>        The form NUM specifies a fraction of the default frame font 
> >> >> height
> >> >>     or width.  The form `(NUM)' specifies an absolute number of pixels.
> >> >
> >> > I admire your courage in reading that documentation and then writing
> >> > stuff like the above, which the documentation doesn't mention even
> >> > remotely.
> >> 
> >> Uh, not sure how to read this, is it irony?
> >
> > Only a little.  I find this area severely under-documented.
> The grammar in the doc seems complete to me.

Do you really think that a formal grammar, whether accurate/complete
or not, is a good way of describing a feature?

reply via email to

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