OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [insight/] [tcl/] [doc/] [split.n] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 578 markom
'\"
2
'\" Copyright (c) 1993 The Regents of the University of California.
3
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
4
'\"
5
'\" See the file "license.terms" for information on usage and redistribution
6
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
7
'\"
8
'\" RCS: @(#) $Id: split.n,v 1.1.1.1 2002-01-16 10:25:25 markom Exp $
9
'\"
10
.so man.macros
11
.TH split n "" Tcl "Tcl Built-In Commands"
12
.BS
13
'\" Note:  do not modify the .SH NAME line immediately below!
14
.SH NAME
15
split \- Split a string into a proper Tcl list
16
.SH SYNOPSIS
17
\fBsplit \fIstring \fR?\fIsplitChars\fR?
18
.BE
19
 
20
.SH DESCRIPTION
21
.PP
22
Returns a list created by splitting \fIstring\fR at each character
23
that is in the \fIsplitChars\fR argument.
24
Each element of the result list will consist of the
25
characters from \fIstring\fR that lie between instances of the
26
characters in \fIsplitChars\fR.
27
Empty list elements will be generated if \fIstring\fR contains
28
adjacent characters in \fIsplitChars\fR, or if the first or last
29
character of \fIstring\fR is in \fIsplitChars\fR.
30
If \fIsplitChars\fR is an empty string then each character of
31
\fIstring\fR becomes a separate element of the result list.
32
\fISplitChars\fR defaults to the standard white-space characters.
33
For example,
34
.CS
35
\fBsplit "comp.unix.misc" .\fR
36
.CE
37
returns \fB"comp unix misc"\fR and
38
.CS
39
\fBsplit "Hello world" {}\fR
40
.CE
41
returns \fB"H e l l o { } w o r l d"\fR.
42
 
43
.SH KEYWORDS
44
list, split, string

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.