vl-string-search
 
 
 

Searches for the specified pattern in a string

(vl-string-search pattern string [start-pos])

Arguments

pattern

A string containing the pattern to be searched for.

string

The string to be searched for pattern.

start-pos

An integer identifying the starting position of the search; 0 if omitted.

Return Values

An integer representing the position in the string where the specified pattern was found; otherwise nil if the pattern is not found; the first character of the string is position 0.

Examples

_$ (vl-string-search "foo"
"pfooyey on you")
1
_$ (vl-string-search "who"
"pfooyey on you")
nil
_$ (vl-string-search "foo"
"fooey-more-fooey" 1)
11