⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 regex.3

📁 <B>Digital的Unix操作系统VAX 4.2源码</B>
💻 3
字号:
.\" SCCSID: @(#)regex.3	8.1	9/11/90.TH regex 3.SH Namere_comp, re_exec \- regular expression handler.SH Syntax.B char *re_comp(s).br.B char *s;.PP.B re_exec(s).br.B char *s;.SH DescriptionThe.NXR "regex keyword".NXR "re_comp subroutine".NXR "re_exec subroutine".NXR "regular expression handler".PN re_compsubroutinecompiles a string into an internal form suitable for pattern matching. The.PN re_exec subroutinechecks the argument string against the last string passed to.PN re_comp ..PPThe.PN re_compsubroutinereturns 0 if the string.I swas compiled successfully; otherwise a string containing anerror message is returned. If .PN re_compis passed 0 or a null string, it returns without changing the currentlycompiled regular expression..PPThe.PN re_execsubroutine returns 1 if the string.I smatches the last compiled regular expression, 0 if the string.I sfailed to match the last compiledregular expression, and \-1 if the compiledregular expression was invalid (indicating an internal error)..PPThe strings passed to both.PN re_compand.PN re_execmay have trailing or embedded newline characters; they are terminated by nulls.The regular expressions recognizedare described in the manual entry for .MS ed 1 ,given the above difference..SH DiagnosticsThe.PN re_execsubroutine returns \-1 for an internal error..PPThe.PN re_compsubroutinereturns one of the following strings if an error occurs:.PP.nf.B "No previous regular expression".B "Regular expression too long".B "unmatched \e(".B "missing ]".B "too many \e(\e) pairs".B "unmatched \e)".fi.SH See Alsoed(1), ex(1), egrep(1), fgrep(1), grep(1)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -