From owner-freebsd-standards@FreeBSD.ORG Wed Jul 2 22:20:22 2014 Return-Path: Delivered-To: freebsd-standards@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 673C134D for ; Wed, 2 Jul 2014 22:20:22 +0000 (UTC) Received: from nm2-vm1.bullet.mail.bf1.yahoo.com (nm2-vm1.bullet.mail.bf1.yahoo.com [98.139.213.158]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 055282886 for ; Wed, 2 Jul 2014 22:20:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1404339614; bh=A8nuwbGmV8LJ5FfxCt+QacQd3MWwoOBCUTA72PehDNo=; h=Received:Received:Received:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:X-Rocket-Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=PoCTDLh12E07wGUMc2SQTVs+wnz8s4hsG7p4lB6Aw9R6K4f14sZYK0/mOTbi8OV/CoyxQTOVM3eHN9UZGo/pACFJE47bcvy9NnSOFFep3ECZ7zp28+WzOongCVYXvLrtkj3f+p8T7/n85E1fQz4+8exHbO5gdpRNW2G28TkxxE2oV8aSknb7tHWBkPOF7BcnOtJ8VB6+qKd8Na2VD/NWzqmtF9W0s5tDJoWcLRAuPsi+hmPnjUiSxt7cNppk8RlA3J3j9L+inP1zuP53Ri6mRyyxCSu9hDCmywaYzA0n/KnG0NyanYnwfrKWB+MvOvdzfBhlfceJBoMnuux8aztRIA== DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s2048; d=yahoo.com; b=ZR4u6tf7ZjnOUWUelaRWiLe7pD36XAUkHS1AQK02VvkDihQxzBTDRQvUYCDx98XDKq5zVa9opqUxpyMyIWzj5YbrmDavoCDQmokZgsIMTf8EdInQyZiE/9fDZL7k9lYfFqvRZM1LROUGvQK4NDBvMbXyGEINAGh5+nmNwUxhLO9RpdE/itoo7x0uly7/D/pnDDIJDSP2Sw7jVgLShpo/2XW9Fd089aVhm3k47wt/jlRYO5Dx8va6NGjS7jDbPldk+rCkFpydnwB/MYp811ujRQgLwFh/zVGLoeKcPHuzwXF5gV5IMg2lfXj4vzwfAba0TgY83KFzqD3JRWqRI4/0zg==; Received: from [98.139.212.153] by nm2.bullet.mail.bf1.yahoo.com with NNFMP; 02 Jul 2014 22:20:14 -0000 Received: from [98.139.211.200] by tm10.bullet.mail.bf1.yahoo.com with NNFMP; 02 Jul 2014 22:20:14 -0000 Received: from [127.0.0.1] by smtp209.mail.bf1.yahoo.com with NNFMP; 02 Jul 2014 22:20:14 -0000 X-Yahoo-Newman-Id: 627077.17279.bm@smtp209.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: YmfKh0UVM1n8Q38B_XbxpTHxLB7Y.jOyw0dKliJ05h7lJe_ NTPgodEddt5zvN0UG4K1DkDL4DkLoiglB7pT_M.mQQ6rPqv3vqDNYGrMg2EW d_8y2QsTLBsxIx8fAPvbF.gLgfyxmTOjrgnbc.fvjHOOp50Ge.fViOug22E_ PW1MP1cOvIShgDUB5hRNaI7pc61ro8_WUMdSAY1EpTpbTC0JE6GwAYlDUaSZ ExO.E3fqiwLUfnvlgeTVUsrRQU0hSGKrqmZyLTxXvO0i0.RyVROR4FeKDaTK vlRjCPJamVoJIRZJ_4VilLAcvZmMVHngbKmWC3_ys9uFfQnky7.2ttiWH0_s e62bjKgyi3x.H9vkq2G9BsB91FopvkFHu4_lcfshXNhOF2pFNtIxhRU0nGF4 f3twc44xhtYTKezxaNYA4h4icKxQKu7HU1aPqnM9TaHhgwyD.9vM4RdlGRf. lsLYWcKfKeZvZDJtIdIFTYbo4Np5_Pp3n3LdsMr7U3jI2mw7m3VZEhM68KsQ fkEAyXhOX2ub9E3MsX8ZEF.LX4TsVj2_x88ZlXbiXalB0HwsxvvxIxhwa2kn _WrhuofxDzjYsfTaecTm4_xeO8FBOF7ZK7GG7GLQBSGA- X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf X-Rocket-Received: from [192.168.0.100] (pfg@190.157.126.109 with plain [98.138.105.21]) by smtp209.mail.bf1.yahoo.com with SMTP; 02 Jul 2014 15:20:14 -0700 PDT Message-ID: <53B485AC.3060706@freebsd.org> Date: Wed, 02 Jul 2014 17:20:28 -0500 From: Pedro Giffuni User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Bryan Drewery Subject: Re: regex(3): support for \< and \> word delimiters References: <53556919.4010305@freebsd.org> <53ADD32C.5040503@FreeBSD.org> <20545470-A847-4835-A42B-382E5CC363ED@freebsd.org> <53B477E6.10103@FreeBSD.org> In-Reply-To: <53B477E6.10103@FreeBSD.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Cc: freebsd-standards@FreeBSD.org X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Jul 2014 22:20:22 -0000 On 07/02/14 16:21, Bryan Drewery wrote: > On 6/27/2014 4:15 PM, Pedro Giffuni wrote: >> Hi; >> >> Il giorno 27/giu/2014, alle ore 15:25, Bryan Drewery ha scritto: >> >>> On 4/21/2014 1:53 PM, Pedro Giffuni wrote: >>>> Hello; >>>> >>>> Is there any related standard (or in absence strong feelings) >>>> about having \< and \> delimiters in regex expressions? >>>> >>>> I have an old PR bin/153257 which actually comes from illumos: >>>> https://www.illumos.org/issues/516 >>>> >>>> I don't use them but maybe it would help people moving their >>>> scripts from Solaris. >>>> >>>> Regards, >>>> >>>> Pedro. >>> I don't know about a standard, but I find the lack of \< \> to be a >>> frustrating difference with other platforms. [[:<:]] [[:>:]] work but >>> are far more characters to type. >>> >> Thank you for the feedback! I had closed the issue because I thought there was no interest. >> >> Another thing that needed consideration was that I thought there was some work going on to replace libregex with libtre, which doesn’t support *any* such delimiter so committing the change would raise the bar for the replacement. Discussing it with Gabor it seems like libtre is not in the capacity of replacing our current libregex anyways so I guess Spencer’s libregex is here to stay. >> >> While here, there is also the sed(1) syntax issue: >> >> https://www.illumos.org/issues/586 >> >> Adopting both changes would probably reduce to a minimum the use of GNU sed in the ports tree, but such changes are likely to be controversial(?) and I don’t feel like wearing asbestos underwear at this time .. at least not for sed ;). >> >> Pedro. >> > IMHO yes that is a good thing to bring over as it helps with people > coming from other platforms and improves portability with scripts. I > started on Linux and kept wondering why I had FILEe files all over my > system until I realized -i '' was required on FreeBSD. > The original idea was, more or less, the contrary: by being stricter about non-standard extensions you can be sure that the code you made on FreeBSD will run unchanged on all existing platforms. It is difficult to strike a balance though: POSIX has been adopting some GNU extensions, so even if we reject them initially at some point they become necessary. The sed enhancement is actually pretty easy, and it looks like, in addition to illumos, NetBSD has it too. It is not high on my todo list though ;). Pedro.