From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 70263 invoked by alias); 30 Jan 2019 19:34:38 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 70256 invoked by uid 89); 30 Jan 2019 19:34:38 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-100.9 required=5.0 tests=BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=expanding X-HELO: mout.kundenserver.de Received: from mout.kundenserver.de (HELO mout.kundenserver.de) (217.72.192.75) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 30 Jan 2019 19:34:36 +0000 Received: from calimero.vinschen.de ([24.134.7.25]) by mrelayeu.kundenserver.de (mreue106 [212.227.15.183]) with ESMTPSA (Nemesis) id 1MRnTQ-1gilkW0mVe-00TC3S for ; Wed, 30 Jan 2019 20:34:34 +0100 Received: by calimero.vinschen.de (Postfix, from userid 500) id 6B402A825EB; Wed, 30 Jan 2019 20:34:33 +0100 (CET) Date: Wed, 30 Jan 2019 19:34:00 -0000 From: Corinna Vinschen To: cygwin@cygwin.com Subject: Re: manpage searches "^\s+keyword\s" vs. ??? Message-ID: <20190130193433.GN3912@calimero.vinschen.de> Reply-To: cygwin@cygwin.com Mail-Followup-To: cygwin@cygwin.com References: <5C4E5F0F.2090403@tlinx.org> <1210066491.20190130214043@yandex.ru> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="j6zkAHxOZJkiczrA" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-SW-Source: 2019-01/txt/msg00299.txt.bz2 --j6zkAHxOZJkiczrA Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 1425 On Jan 30 13:09, Eric Blake wrote: > On 1/30/19 12:40 PM, Andrey Repin wrote: >=20 > >=20 > > I've been puzzled by this since=E2=80=A6 forever, it seems. > > This is something in less, but all the `man less` says is "regular expr= ession > > library provided by your system". >=20 > \s is a non-standard regex extension - glibc provides it, Cygwin has not > (at least, historically). POSIX provides [[:space:]] as a portable > alternative (although not all libc have implemented all of POSIX yet), > but is annoyingly long to type. >=20 > Similarly, BSD regex (which is where Cygwin derives its regex from) > supports the non-standard regex extension [[:<:]] as a word boundary, > while glibc has the same feature but spelled \<. I also seem to recall > a patch in the past to teach Cygwin to respect \< by expanding it to > [[:<:]] before calling into the BSD-derived code (although I couldn't > actually find one in a quick search); a similar patch to expand \s into > [[:space:]] would be a reasonable idea. >=20 > > I guess this is down to compilation options at this point. >=20 > Not so much compilation options of man and less, but rather the code > used in Cygwin itself for handling regex. FreeBSD code since we can't use glibc code for licensing reasons. As usual: Patches welcome! (Even a complet replacement wouldn't hurt as long as licensing is no issue) Corinna --=20 Corinna Vinschen Cygwin Maintainer --j6zkAHxOZJkiczrA Content-Type: application/pgp-signature; name="signature.asc" Content-length: 833 -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlxR/EkACgkQ9TYGna5E T6BHnw//Vjd+Bf8OZNsn3jGX0cHR4KsK1Lo9OISKdyFj1AIAQr7oTFAYH212Yh8O DLe+00uSOUM9xmYxnl/Rm+5DkfDgwOwYpWq5bqTtVLDsUUnN+ZhxPG13NTaPVytX l2hqsbEyM62Iw0XC4cutL3Tlrqe6OUZ2RHNfsuNXtBF5qDyrDQuzJo9eqqyhzaxZ kn2nX8wOLgeHOHCauTKJM9KiVonnXDmwJc4FUvB4WZdUZhx0VlEBmAw45CfT6vTp VG07laBEX4mNxn7xFRd4iXtHiSs8dKK57JIXSNQ8lKx8u7D41fINXOFYLo2d+iLQ +L2QSMm/SvZXX5fVcMlzXF9i28pHNxXNQcUO/gOKDyux20Mc3ZETuXvQz3ACb6vl hbIFXMwHK/5hl/NfBVSSOyA5ZU5kq+DqeoxXXuiAPMGbykmdbyxt9V3WOvXNkHTD KkY8sqV5OOv8aWfubYZiRTByYsFt7+zGbbpCZ2mNB7Z3eE68rnQUp0/pazI2qptb MXmNnqYtOe5SXNevegkx+MRAi1cH++OXOmdX6mV75dfu56ONCrvEfCfK/zW2XZ7o UeLZ/korwloZtjzPVPfX4Jf4+m0JlQ0fNY7gA9Nn26spOBskN7tY+XGnR0KCYrJ+ lXyd60rCqpfz19lQkmS3RbDpML3RP+nZzkAxq3B/kDTwWxeag/k= =uGBX -----END PGP SIGNATURE----- --j6zkAHxOZJkiczrA--