[219] in Coldmud discussion meeting
stridx()
daemon@ATHENA.MIT.EDU (Sun May 1 01:04:20 1994
)
Date: Sat, 30 Apr 1994 23:00:44 -0600 (MDT)
From: the Lyncx <BRANDON@cc.usu.edu>
To: coldstuff@MIT.EDU
X-Vms-To: COLDSTUFF
Anybody have any feelings on a builtin along the lines of:
stridx("string", "search for"[, 'reverse])
Which would return an index of "search for" in "string" (beginning of "search
for" if "search for" is not a char). It would return a reverse index if a
third argument was sent.
Comments?
This just hit me, I coded an index() and rindex() on $string a while ago, and
they are used enough I feel it would merit a builtin (heck, we have a builtin
for the end/null index of the string (i.e. 'strlen()').
-Brandon-