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

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

Re: Different behaviour while debugging?


From: Thorsten Jolitz
Subject: Re: Different behaviour while debugging?
Date: Sat, 23 Feb 2013 10:07:22 +0100
User-agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.2 (gnu/linux)

Andreas Röhler <andreas.roehler@easy-emacs.de> writes:

>> I have the very strange case that a program - in some special situation
>> - does not work as expected, but when I instrument the relevant
>> function(s) for edebug and single-step through them, everythings works
>> as expected and the output is fine.
>
> IMHO that's possible, for example if some function expects faces, which are 
> only there if
> fontification is done

At the surface of my application program, there are no faces involved,
its about recognizing if there is a comment on a line with
'comment-on-line-p', which calls 'comment-search-forward', which
searches for 'comment-start-skip'. 

Since, when in html-mode, the following condition-case (inside a 'cond
structure) is never entered in normal execution but is correctly entered
when (e)debugging, I would guess the 'comment-on-line-p' makes the
difference. 

         ,---------------------------------------------------
         | ((and
         |   (save-excursion
         |     (not (eq (comment-on-line-p) (point-at-bol))))
         |   last-line-comment-p) ...)
         `---------------------------------------------------

And, actually, if I edebug 'comment-search-forward', things work as
expected, just like when I edebug my own function that contains the
above condition-case. 

> try some (sit-for) then

ok - thanks for the tip. 

-- 
cheers,
Thorsten




reply via email to

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