]>
git.saurik.com Git - bison.git/blob - lib/strspn.c
1 /* Copyright (C) 1991, 1997 Free Software Foundation, Inc.
3 NOTE: The canonical source of this file is maintained with the GNU
4 C Library. Bugs can be reported to bug-glibc@prep.ai.mit.edu.
6 This program is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Library General Public License
8 as published by the Free Software Foundation; either version 2 of
9 the License, or (at your option) any later version.
11 This program is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Library General Public License for more details.
16 You should have received a copy of the GNU Library General Public
17 License along with this program; see the file COPYING.LIB. If not,
18 write to the Free Software Foundation, Inc., 59 Temple Place -
19 Suite 330, Boston, MA 02111-1307, USA. */
25 #if defined _LIBC || HAVE_STRING_H
36 /* Return the length of the maximum initial segment
37 of S which contains only characters in ACCEPT. */
47 for (p
= s
; *p
!= '\0'; ++p
)
49 for (a
= accept
; *a
!= '\0'; ++a
)