Re: [PATCH] wip: change ISSPACE to use ascii whitespace check.

Crystal Kolipe via Mutt-dev <[email protected]>
Newsgroups gmane.mail.mutt.devel
Message-ID <[email protected]>
On Wed, Feb 18, 2026 at 03:29:57PM +0100, Alejandro Colomar via Mutt-dev wrote:
> BTW, with the macros shown above, one could implement:
> 
> 	#define streq(a,b)  (strcmp(a,b) == 0)
> 
> 	#define isspace_c(c)            (!streq(strchrnul(MUTT_CTYPE_SPACE_C, c), ""))
> 	#define isspace_rfc5322_fws(c)  (!streq(strchrnul(MUTT_CTYPE_RFC5322_FWS, c), ""))
> 
> Although, in general, using the strspn(3) family of functions directly
> seems more ergonomic.

Note that strchrnul() is not available natively on OpenBSD.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.