.\" Copyright (C), 1995, Graeme W. Wilford. (Wilf.) .\" .\" %%%LICENSE_START(VERBATIM) .\" Permission is granted to make and distribute verbatim copies of this .\" manual provided the copyright notice and this permission notice are .\" preserved on all copies. .\" .\" Permission is granted to copy and distribute modified versions of this .\" manual under the conditions for verbatim copying, provided that the .\" entire resulting derived work is distributed under the terms of a .\" permission notice identical to this one. .\" .\" Since the Linux kernel and libraries are constantly changing, this .\" manual page may be incorrect or out-of-date. The author(s) assume no .\" responsibility for errors or omissions, or for damages resulting from .\" the use of the information contained herein. The author(s) may not .\" have taken the same level of care in the production of this manual, .\" which is licensed free of charge, as they might when working .\" professionally. .\" .\" Formatted or processed versions of this manual, if unaccompanied by .\" the source, must acknowledge the copyright and authors of this work. .\" %%%LICENSE_END .\" .\" Wed Jun 14 16:10:28 BST 1995 Wilf. (G.Wilford@@ee.surrey.ac.uk) .\" .\"******************************************************************* .\" .\" This file was generated with po4a. Translate the source file. .\" .\"******************************************************************* .\" .\" Japanese Version Copyright (c) 1997 HIROFUMI Nishizuka .\" all rights reserved. .\" Translated Thu Dec 18 15:06:31 JST 1997 .\" by HIROFUMI Nishizuka .\" .TH RE_COMP 3 2017\-09\-15 GNU "Linux Programmer's Manual" .SH 名前 re_comp, re_exec \- BSD の正規表現関数 .SH 書式 \fB#define _REGEX_RE_COMP\fP .br \fB#include \fP .br \fB#include \fP .PP \fBchar *re_comp(const char *\fP\fIregex\fP\fB);\fP .PP \fBint re_exec(const char *\fP\fIstring\fP\fB);\fP .SH 説明 \fBre_comp\fP() は、 \fIregex\fP で示されるヌルで終端された正規表現をコンパイルするために使用される。 コンパイルされたパターンは静的な領域を使用しており、そのパターンバッファー は以降の \fBre_comp\fP() の使用によって上書きされる。 もし \fIregex\fP が NULL ならば何の操作も行われず、パターンバッファーの内容は 置き換えられない。 .PP \fBre_exec\fP() は、 \fIstring\fP が指すヌルで終端された文字列が前回コンパイルされた \fIregex\fP にマッチするかどうかを評価するために使用される。 .SH 返り値 \fBre_comp\fP() は、 \fIregex\fP のコンパイルに成功した場合 NULL を返し、 それ以外の場合は適切なエラーメッセージへのポインターを返す。 .PP \fBre_exec\fP() は、一致した場合 1 を、失敗した場合 0 を返す。 .SH 属性 この節で使用されている用語の説明については、 \fBattributes\fP(7) を参照。 .TS allbox; lbw20 lb lb l l l. インターフェース 属性 値 T{ \fBre_comp\fP(), \fBre_exec\fP() T} Thread safety MT\-Unsafe .TE .SH 準拠 4.3BSD. .SH 注意 これらの関数は廃止予定である。代わりに \fBregcomp\fP(3) に書かれている関数を使用すべきである。 .SH 関連項目 \fBregcomp\fP(3), \fBregex\fP(7), GNU regex manual .SH この文書について この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は \%https://www.kernel.org/doc/man\-pages/ に書かれている。