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

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

Re: [SOLVED] Re: (rx regexp to remove space and new lines


From: Michael Albinus
Subject: Re: [SOLVED] Re: (rx regexp to remove space and new lines
Date: Tue, 13 Sep 2022 16:29:44 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

<tomas@tuxteam.de> writes:

>> rx transforms 'whitespace' to [:space:].
>>
>> But (info "(elisp) Char Classes") told me that "[:space:] [...] matches
>> any character that has whitespace syntax (*note Syntax Class Table)", so I
>> assumed that the meaning is not constant... or is it?
>
> Good question. I'll check once I'm off work (unless someone else beats me
> to it, that is).

(rx blank) might be the better choice. Adding CR and LF to the puzzle,
I'd use (rx (any "\n\r" blank))

> Cheers

Best regards, Michael.



reply via email to

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