From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.devel Subject: Re: "Raw" string literals for elisp Date: Wed, 8 Sep 2021 23:11:00 +0200 Message-ID: References: <4209edd83cfee7c84b2d75ebfcd38784fa21b23c.camel@crossproduct.net> <8735qeg9ed.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23894"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Alan Mackenzie , Emacs developers , Anna Glasgall , Stefan Monnier , =?UTF-8?Q?Mattias_Engdeg=C3=A5rd?= To: Philip Kaludercic Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Sep 08 23:12:07 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 1mO4rW-00064H-Jf for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Sep 2021 23:12:06 +0200 Original-Received: from localhost ([::1]:58038 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mO4rV-0002rw-K3 for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Sep 2021 17:12:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45404) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mO4qi-0001Zo-G0 for emacs-devel@gnu.org; Wed, 08 Sep 2021 17:11:16 -0400 Original-Received: from mail-pj1-f51.google.com ([209.85.216.51]:41649) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mO4qf-0000zr-TW for emacs-devel@gnu.org; Wed, 08 Sep 2021 17:11:16 -0400 Original-Received: by mail-pj1-f51.google.com with SMTP id m21-20020a17090a859500b00197688449c4so2485714pjn.0 for ; Wed, 08 Sep 2021 14:11:13 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=pPhNqjp+r7YKyMZzOpTYqYE/YD/taS5xuNbwOq4WKNE=; b=MfXLNUhHfGp7OwBYiMwvR2Un9EUL7nM0BKXA7dCUusleQq+tZI6s8tbr7hu/f8a1hB j1yLKuKrL4kE+M3f41zh4KiYjapEdZFVTD+S/gy7esEtFuKwMaXX5dn6uor/roQ/uTbB QyJIWyj0rbDr99IyEItLCZwuCmKIv15ztOY8CjyDGiZ8RldoYyHRR+0D3ael6qseZuw1 UzmCUuYapKQ0xmSbCFbxOlzEYbo4s7lRsd0uqJzyaJFoDREgpkm5FUGjypPLW7DZ/PTe wEVJYA+wDAF5cvhlJ18RoYkuOwQoJZlV/0uDyDqyXIHRgzprgco5EqXL/LVmrMshHvLM adBw== X-Gm-Message-State: AOAM530ijZCuFI9c+ntmb6s433+5j3gt7ofb97lJOGxmqeIZf/D9FN23 LUpR92Kcwkt2BLjD/8XLYuuVjwbDJ37WdTbTg6U= X-Google-Smtp-Source: ABdhPJziHRw+RoAktVQ/aCK2DIEvSGKV7rCzIbW1doc5Oq4t9+AysUTfp6rQEpJdOlze0w62yQ+VOSZbY51Ulecgy3w= X-Received: by 2002:a17:903:18b:b0:139:eef4:9eb0 with SMTP id z11-20020a170903018b00b00139eef49eb0mr104578plg.32.1631135472416; Wed, 08 Sep 2021 14:11:12 -0700 (PDT) In-Reply-To: <8735qeg9ed.fsf@posteo.net> Received-SPF: pass client-ip=209.85.216.51; envelope-from=stefankangas@gmail.com; helo=mail-pj1-f51.google.com X-Spam_score_int: -13 X-Spam_score: -1.4 X-Spam_bar: - X-Spam_report: (-1.4 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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:274393 Archived-At: Philip Kaludercic writes: > 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). Perl has this: perl -e '$foo = "bar"; print "yes" if $foo =~ / bar # comment /x;' is equivalent to perl -e '$foo = "bar"; print "yes" if $foo =~ /bar/;'