From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Newsgroups: gmane.emacs.devel Subject: Re: "Raw" string literals for elisp Date: Thu, 9 Sep 2021 08:52:41 +0200 Message-ID: <20210909065241.GA16259@tuxteam.de> References: <4209edd83cfee7c84b2d75ebfcd38784fa21b23c.camel@crossproduct.net> <8735qeg9ed.fsf@posteo.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="u3/rZRmxL6MmkK24" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32888"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mutt/1.5.21 (2010-09-15) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Sep 09 08:53:58 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mODwc-0008Nw-AR for ged-emacs-devel@m.gmane-mx.org; Thu, 09 Sep 2021 08:53:58 +0200 Original-Received: from localhost ([::1]:41534 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mODwb-0007JI-1L for ged-emacs-devel@m.gmane-mx.org; Thu, 09 Sep 2021 02:53:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:42802) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mODvR-0006K9-PH for emacs-devel@gnu.org; Thu, 09 Sep 2021 02:52:46 -0400 Original-Received: from mail.tuxteam.de ([5.199.139.25]:56217) by eggs.gnu.org with esmtps (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.90_1) (envelope-from ) id 1mODvP-0002rr-NL for emacs-devel@gnu.org; Thu, 09 Sep 2021 02:52:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tuxteam.de; s=mail; h=From:In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:To:Date; bh=6VEE16A3zWxpLVimZn8LXFh0E9c18BPgDR/t/obOaEc=; b=VVa+HqJOciLDJjgbKsTknTwm+9jwPYSu3T5cgQnXJY5nHPhUfg8z7QfFxO6Wk52mT0Tbvp3RuYViht70kec/mMZwZTqQPe5ofnWFgpsMYLyi2aatkYlPh2A65Z776EA8i4lJ03QcEFcWghcrPSaoPUXjYuhRxmQEs6FTVdUerCgZe5i0jlfZXcY1VjRT+V6XYw8tTBoGeCImHtx3JePPFLt9SwyU+PsWEmoDGJ92DMIF1CTBBR4Z56Xq7KBiEzqFFv31oGw6mdzOV/jxT4/qwhbyw2T77B8FHwttDf4CvWg/xXzRiBw0lyFQ9lH7/DbSy/FQVY9SY1WU0SY+ZBiblg==; Original-Received: from tomas by mail.tuxteam.de with local (Exim 4.80) (envelope-from ) id 1mODvN-0004NR-Am for emacs-devel@gnu.org; Thu, 09 Sep 2021 08:52:41 +0200 Content-Disposition: inline In-Reply-To: Received-SPF: pass client-ip=5.199.139.25; envelope-from=tomas@tuxteam.de; helo=mail.tuxteam.de X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:274427 Archived-At: --u3/rZRmxL6MmkK24 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 08, 2021 at 11:11:00PM +0200, Stefan Kangas wrote: > Philip Kaludercic writes: >=20 > > The reason I use rx in a lot of my scripts is that I can add comments, > > explanations, formatting, etc. when it gets complicated. I think that is > > a significant advantage, that even raw strings wouldn't have (unless a > > comment syntax were to be added into the regular expression language, > > which is unlikely). >=20 > Perl has this: >=20 > perl -e '$foo =3D "bar"; print "yes" if $foo =3D~ / bar # comment /x;' Yes, Perl's "extended" regexps. They are very handy for when the concise language is too cunfusing. I'd tend to the position that this "ecological niche" is already (very well) covered by `rx'. But I am aware that this is a very subjective topic :) Cheers - t --u3/rZRmxL6MmkK24 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAmE5rzkACgkQBcgs9XrR2kZNHgCdEW4aV3OMbD35+ZK1/Qo+Xnh/ V/YAn0AL4mF91NJBViic+JcL3jv5EB83 =8SBN -----END PGP SIGNATURE----- --u3/rZRmxL6MmkK24--