[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: To `boundp' or not to `boundp'?
From: |
Stefan Monnier |
Subject: |
Re: To `boundp' or not to `boundp'? |
Date: |
Tue, 01 Sep 2015 22:12:59 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
> (when (and (boundp 'xxx-mode) xxx-mode)
> ...)
> I personally prefer to do it shorter
> (when (ignore-errors xxx-mode)
> ...)
> Are those equivalent?
Kinda. I think ignore-errors has a higher cost than boundp+and, but the
more important difference is that ignore-errors will hide all kinds of
other errors, so its use generally makes debugging your code harder.
For that reason I generally prefer to avoid it.
Stefan
- RE: member returns list, (continued)
- member (was: Re: To `boundp' or not to `boundp'?), Emanuel Berg, 2015/09/01
- Message not available
- Re: member returns list (was: Re: To `boundp' or not to `boundp'?), Barry Margolin, 2015/09/02
- Re: member returns list (was: Re: To `boundp' or not to `boundp'?), Emanuel Berg, 2015/09/02
- Message not available
- Re: member returns list (was: Re: To `boundp' or not to `boundp'?), Barry Margolin, 2015/09/02
- Re: member returns list (was: Re: To `boundp' or not to `boundp'?), Emanuel Berg, 2015/09/02
- Message not available
- Re: member, Pascal J. Bourguignon, 2015/09/03
- Re: member, Emanuel Berg, 2015/09/03
Re: To `boundp' or not to `boundp'?,
Stefan Monnier <=