[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Elisp string function question
From: |
Emanuel Berg |
Subject: |
Re: Elisp string function question |
Date: |
Sun, 20 Jun 2021 03:15:17 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
>>
>> Thanks for mentioning `string-empty-p' BTW, didn't know of
>> that, now I can remove my own `empty-string-p' :P
>>
>> (which shows the same bahavior BTW)
>
> No, it doesn't, why did I ever remove it? I thought it was the
> same as this but it wasn't, (string-empty-p nil) should be
> t according to the way I've been using it! Christ, no wonder
> nothing works all of a sudden.
What I want is
(defun string-data-p (str)
(and (stringp str)
(not (string= str "")) ))
Is it a string?
Does it have data?
nil and "" is (here) just as useless.
But the funny thing is, my "empty-string-p" looked like
`string-empty-p', that's why I replaced the calls to that
instead. Then everything broke. So I guess it didn't look
quite like that after all...
--
underground experts united
https://dataswamp.org/~incal
- Re: Elisp string function question, (continued)
Re: Elisp string function question, Stefan Monnier, 2021/06/18
Re: Elisp string function question, Michael Heerdegen, 2021/06/18
Re: Elisp string function question, Emanuel Berg, 2021/06/18
Re: Elisp string function question, Michael Heerdegen, 2021/06/18