X-Git-Url: https://git.saurik.com/apple/libc.git/blobdiff_plain/fbd86d4cc20b02a10edcca92fb7ae0a143e63cc4..1f2f436a38f7ae2d39a943ad2898d8fed4ed2e58:/regex/regex.3 diff --git a/regex/regex.3 b/regex/regex.3 index 9f6b115..dc3b5bf 100644 --- a/regex/regex.3 +++ b/regex/regex.3 @@ -13,10 +13,6 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" 3. All advertising materials mentioning features or use of this software -.\" must display the following acknowledgement: -.\" This product includes software developed by the University of -.\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. @@ -34,9 +30,9 @@ .\" SUCH DAMAGE. .\" .\" @(#)regex.3 8.4 (Berkeley) 3/20/94 -.\" $FreeBSD: src/lib/libc/regex/regex.3,v 1.17 2004/07/12 11:03:42 tjr Exp $ +.\" $FreeBSD: src/lib/libc/regex/regex.3,v 1.21 2007/01/09 00:28:04 imp Exp $ .\" -.Dd July 12, 2004 +.Dd August 17, 2005 .Dt REGEX 3 .Os .Sh NAME @@ -444,7 +440,7 @@ places the NUL-terminated message into the buffer pointed to by limiting the length (including the NUL) to at most .Fa errbuf_size bytes. -If the whole message won't fit, +If the whole message will not fit, as much of it as will fit before the terminating NUL is supplied. In any case, the returned value is the size of buffer needed to hold the whole @@ -596,14 +592,6 @@ and beginning and ending subexpressions in obsolete .Pq Dq basic REs are anchors, not ordinary characters. -.Sh SEE ALSO -.Xr grep 1 , -.Xr re_format 7 -.Pp -.St -p1003.2 , -sections 2.8 (Regular Expression Notation) -and -B.5 (C Binding for Regular Expression Matching). .Sh DIAGNOSTICS Non-zero error codes from .Fn regcomp @@ -657,12 +645,20 @@ operand invalid .It Dv REG_EMPTY empty (sub)expression .It Dv REG_ASSERT -can't happen - you found a bug +cannot happen - you found a bug .It Dv REG_INVARG invalid argument, e.g.\& negative-length string .It Dv REG_ILLSEQ illegal byte sequence (bad multibyte character) .El +.Sh SEE ALSO +.Xr grep 1 , +.Xr re_format 7 +.Pp +.St -p1003.2 , +sections 2.8 (Regular Expression Notation) +and +B.5 (C Binding for Regular Expression Matching). .Sh HISTORY Originally written by .An Henry Spencer . @@ -723,7 +719,7 @@ are legal REs because is a special character only in the presence of a previous unmatched .Ql (\& . -This can't be fixed until the spec is fixed. +This cannot be fixed until the spec is fixed. .Pp The standard's definition of back references is vague. For example, does @@ -735,3 +731,5 @@ behavior in such cases should not be relied on. .Pp The implementation of word-boundary matching is a bit of a kludge, and bugs may lurk in combinations of word-boundary matching and anchoring. +.Pp +Word-boundary matching does not work properly in multibyte locales.