Blame src/kwset.h

Packit 709fb3
/* kwset.h - header declaring the keyword set library.
Packit 709fb3
   Copyright (C) 1989, 1998, 2005, 2007, 2009-2017 Free Software Foundation,
Packit 709fb3
   Inc.
Packit 709fb3
Packit 709fb3
   This program is free software; you can redistribute it and/or modify
Packit 709fb3
   it under the terms of the GNU General Public License as published by
Packit 709fb3
   the Free Software Foundation; either version 3, or (at your option)
Packit 709fb3
   any later version.
Packit 709fb3
Packit 709fb3
   This program is distributed in the hope that it will be useful,
Packit 709fb3
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 709fb3
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit 709fb3
   GNU General Public License for more details.
Packit 709fb3
Packit 709fb3
   You should have received a copy of the GNU General Public License
Packit 709fb3
   along with this program; if not, write to the Free Software
Packit 709fb3
   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
Packit 709fb3
   02110-1301, USA.  */
Packit 709fb3
Packit 709fb3
/* Written August 1989 by Mike Haertel.  */
Packit 709fb3
Packit 709fb3
#include <stddef.h>
Packit 709fb3
#include <stdbool.h>
Packit 709fb3
Packit 709fb3
struct kwsmatch
Packit 709fb3
{
Packit 709fb3
  ptrdiff_t index;			/* Index number of matching keyword.  */
Packit 709fb3
  ptrdiff_t offset[1];		/* Offset of match.  */
Packit 709fb3
  ptrdiff_t size[1];		/* Length of match.  */
Packit 709fb3
};
Packit 709fb3
Packit 709fb3
#include "arg-nonnull.h"
Packit 709fb3
Packit 709fb3
struct kwset;
Packit 709fb3
typedef struct kwset *kwset_t;
Packit 709fb3
Packit 709fb3
extern kwset_t kwsalloc (char const *);
Packit 709fb3
extern void kwsincr (kwset_t, char const *, ptrdiff_t);
Packit 709fb3
extern ptrdiff_t kwswords (kwset_t) _GL_ATTRIBUTE_PURE;
Packit 709fb3
extern void kwsprep (kwset_t);
Packit 709fb3
extern ptrdiff_t kwsexec (kwset_t, char const *, ptrdiff_t,
Packit 709fb3
                          struct kwsmatch *, bool)
Packit 709fb3
  _GL_ARG_NONNULL ((4));
Packit 709fb3
extern void kwsfree (kwset_t);