Mercurial > urweb
diff src/c/urweb.c @ 831:5e1a4b12c83a
strcspn and friends
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 31 May 2009 12:41:34 -0400 |
parents | 20fe00fd81da |
children | 249740301a0a |
line wrap: on
line diff
--- a/src/c/urweb.c Sat May 30 14:44:29 2009 -0400 +++ b/src/c/urweb.c Sun May 31 12:41:34 2009 -0400 @@ -1815,6 +1815,10 @@ return strchr(s, ch); } +uw_Basis_int uw_Basis_strcspn(uw_context ctx, uw_Basis_string s, uw_Basis_string chs) { + return strcspn(s, chs); +} + uw_Basis_int *uw_Basis_strindex(uw_context ctx, uw_Basis_string s, uw_Basis_char ch) { uw_Basis_string r = strchr(s, ch); if (r == NULL)