From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16114 invoked by alias); 4 Apr 2017 15:53:02 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 22658 Received: (qmail 13579 invoked from network); 4 Apr 2017 15:53:01 -0000 X-Qmail-Scanner-Diagnostics: from mta02.eastlink.ca by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(24.224.136.13):SA:0(-0.7/5.0):. Processed in 1.00237 secs); 04 Apr 2017 15:53:01 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW, RP_MATCHES_RCVD,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: rayandrews@eastlink.ca X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.eastlink.ca designates 24.224.136.13 as permitted sender) X-Authority-Analysis: v=2.2 cv=O5RJhF1W c=1 sm=1 tr=0 a=vxT7m9cC8jqSb+vgEp6olw==:117 a=vxT7m9cC8jqSb+vgEp6olw==:17 a=N659UExz7-8A:10 a=J5HxtG0EyPJaCh3G-uAA:9 a=pILNOxqGKmIA:10 X-EL-IP-NOAUTH: 24.207.108.252 From: Ray Andrews Subject: Re: REMATCH_PCRE with zsh built without pcre support To: zsh-users@zsh.org References: <27c2026c-f760-32b0-e0d5-8c6909346979@gmx.com> <170401145348.ZM30308@torch.brasslantern.com> <20170403011159.GA64116@tower.spodhuis.org> <20170403112611.GA4333@fujitsu.shahaf.local2> <170403110016.ZM12756@torch.brasslantern.com> <20170404003649.GA6581@fujitsu.shahaf.local2> <170403194343.ZM13808@torch.brasslantern.com> Message-id: Date: Tue, 04 Apr 2017 08:22:52 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-version: 1.0 In-reply-to: <170403194343.ZM13808@torch.brasslantern.com> Content-type: text/plain; charset=windows-1252; format=flowed Content-transfer-encoding: 7bit On 03/04/17 07:43 PM, Bart Schaefer wrote: > Certainly one approach would be to always use pcre when it is loaded, and > always use regex when it is not, and only throw an error when neither of > them is available. That would only introduce a problem if someone is > expecting regex semantics out of a pattern that is valid in both cases > but means something else in pcre semantics. I'm not going to give myself > a headache trying to construct an example. Pardon, I don't understand the details of any of this, but would not the above be setting a time-bomb? Surely it should be explicit which method is being used and one should never crash into something like: "Oh! I've been thinking I was using pcre all this time and now I see that it's really regex." or: "I want regex but since that's not available I'm getting pcre whether I want it or not, it seems." Friendly fall-backs might seem friendly, but if they are doing something without explicit approval or maybe explicit notification are they not gotchas waiting to sabotage you? This is one of my philosophical musings, just ignore it if it's not worth answering.