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

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

RE: [External] : Tip: Debugging with function `message-box'


From: Drew Adams
Subject: RE: [External] : Tip: Debugging with function `message-box'
Date: Thu, 24 Jun 2021 18:49:44 +0000

> I find it often easier to debug values of some variables by using the
> function `message-box' instead of just `message':
> 
> (message-box "%s" "Hello")
> 
> Unlike the function `message' this one blocks the execution for a
> while, or until confirmed. This is useful in various debugging
> processes.

Sure.  Some alternatives, just for info:

To just pause so you can see the message (which gets
logged to `*Messages*' anyway), you can use `sit-for'
or `sleep-for'.  E.g. `(message "...")(sleep-for 2)'.

To block until confirmed, you can use `(debug)'.
(`c' to just confirm.)  And `(debug nil <whatever>)'
prints the <whatever> at the top of the debugger
(like a message).



reply via email to

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