diff options
author | dkf <dkf@noemail.net> | 2004-03-17 00:57:19 (GMT) |
---|---|---|
committer | dkf <dkf@noemail.net> | 2004-03-17 00:57:19 (GMT) |
commit | 10d89fde08fae09704162493274a22d3b257ceb8 (patch) | |
tree | 24e61dab0ac7231432c6bbcb7221ea0fc959b0c6 /doc/lsearch.n | |
parent | 11ea0bef7e11b083f06ee51e62ffbf0e8d02ffbc (diff) | |
download | tcl-10d89fde08fae09704162493274a22d3b257ceb8.zip tcl-10d89fde08fae09704162493274a22d3b257ceb8.tar.gz tcl-10d89fde08fae09704162493274a22d3b257ceb8.tar.bz2 |
Slightly better docs for [lsearch]'s advanced capabilities
FossilOrigin-Name: da98392a5d7b3b1f304c6a389c4ff2f764799cf6
Diffstat (limited to 'doc/lsearch.n')
-rw-r--r-- | doc/lsearch.n | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/doc/lsearch.n b/doc/lsearch.n index b2129aa..74e8451 100644 --- a/doc/lsearch.n +++ b/doc/lsearch.n @@ -6,7 +6,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: lsearch.n,v 1.15 2003/10/14 13:38:57 dkf Exp $ +'\" RCS: @(#) $Id: lsearch.n,v 1.16 2004/03/17 00:57:20 dkf Exp $ '\" .so man.macros .TH lsearch n 8.5 Tcl "Tcl Built-In Commands" @@ -124,11 +124,20 @@ precedence. .CS lsearch {a b c d e} c => 2 lsearch -all {a b c a b c} c => 2 5 + +\fI# Filtering examples\fR lsearch -inline {a20 b35 c47} b* => b35 lsearch -inline -not {a20 b35 c47} b* => a20 lsearch -all -inline -not {a20 b35 c47} b* => a20 c47 lsearch -all -not {a20 b35 c47} b* => 0 2 +\fI# Simple set removal\fR +lsearch -all -inline -not -exact {a b c a d e a f g a} a + => b c d e f g + +\fI# Non-start based searches\fR lsearch -start 3 {a b c a b c} c => 5 + +\fI# Searching inside elements\fR lsearch -index 1 -all {{a abc} {b bcd} {c cde}} *bc* => {a abc} {b bcd} .CE |