OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gdb-6.8/] [readline/] [histlib.h] - Diff between revs 157 and 816

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 157 Rev 816
/* histlib.h -- internal definitions for the history library. */
/* histlib.h -- internal definitions for the history library. */
/* Copyright (C) 1989, 1992 Free Software Foundation, Inc.
/* Copyright (C) 1989, 1992 Free Software Foundation, Inc.
 
 
   This file contains the GNU History Library (the Library), a set of
   This file contains the GNU History Library (the Library), a set of
   routines for managing the text of previously typed lines.
   routines for managing the text of previously typed lines.
 
 
   The Library is free software; you can redistribute it and/or modify
   The Library is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 2, or (at your option)
   the Free Software Foundation; either version 2, or (at your option)
   any later version.
   any later version.
 
 
   The Library is distributed in the hope that it will be useful, but
   The Library is distributed in the hope that it will be useful, but
   WITHOUT ANY WARRANTY; without even the implied warranty of
   WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   General Public License for more details.
   General Public License for more details.
 
 
   The GNU General Public License is often shipped with GNU software, and
   The GNU General Public License is often shipped with GNU software, and
   is generally kept in a file called COPYING or LICENSE.  If you do not
   is generally kept in a file called COPYING or LICENSE.  If you do not
   have a copy of the license, write to the Free Software Foundation,
   have a copy of the license, write to the Free Software Foundation,
   59 Temple Place, Suite 330, Boston, MA 02111 USA. */
   59 Temple Place, Suite 330, Boston, MA 02111 USA. */
 
 
#if !defined (_HISTLIB_H_)
#if !defined (_HISTLIB_H_)
#define _HISTLIB_H_
#define _HISTLIB_H_
 
 
#if defined (HAVE_STRING_H)
#if defined (HAVE_STRING_H)
#  include <string.h>
#  include <string.h>
#else
#else
#  include <strings.h>
#  include <strings.h>
#endif /* !HAVE_STRING_H */
#endif /* !HAVE_STRING_H */
 
 
#if !defined (STREQ)
#if !defined (STREQ)
#define STREQ(a, b)     (((a)[0] == (b)[0]) && (strcmp ((a), (b)) == 0))
#define STREQ(a, b)     (((a)[0] == (b)[0]) && (strcmp ((a), (b)) == 0))
#define STREQN(a, b, n) (((n) == 0) ? (1) \
#define STREQN(a, b, n) (((n) == 0) ? (1) \
                                    : ((a)[0] == (b)[0]) && (strncmp ((a), (b), (n)) == 0))
                                    : ((a)[0] == (b)[0]) && (strncmp ((a), (b), (n)) == 0))
#endif
#endif
 
 
#ifndef savestring
#ifndef savestring
#define savestring(x) strcpy (xmalloc (1 + strlen (x)), (x))
#define savestring(x) strcpy (xmalloc (1 + strlen (x)), (x))
#endif
#endif
 
 
#ifndef whitespace
#ifndef whitespace
#define whitespace(c) (((c) == ' ') || ((c) == '\t'))
#define whitespace(c) (((c) == ' ') || ((c) == '\t'))
#endif
#endif
 
 
#ifndef _rl_digit_p
#ifndef _rl_digit_p
#define _rl_digit_p(c)  ((c) >= '0' && (c) <= '9')
#define _rl_digit_p(c)  ((c) >= '0' && (c) <= '9')
#endif
#endif
 
 
#ifndef _rl_digit_value
#ifndef _rl_digit_value
#define _rl_digit_value(c) ((c) - '0')
#define _rl_digit_value(c) ((c) - '0')
#endif
#endif
 
 
#ifndef member
#ifndef member
#  ifndef strchr
#  ifndef strchr
extern char *strchr ();
extern char *strchr ();
#  endif
#  endif
#define member(c, s) ((c) ? ((char *)strchr ((s), (c)) != (char *)NULL) : 0)
#define member(c, s) ((c) ? ((char *)strchr ((s), (c)) != (char *)NULL) : 0)
#endif
#endif
 
 
#ifndef FREE
#ifndef FREE
#  define FREE(x)       if (x) free (x)
#  define FREE(x)       if (x) free (x)
#endif
#endif
 
 
/* Possible history errors passed to hist_error. */
/* Possible history errors passed to hist_error. */
#define EVENT_NOT_FOUND 0
#define EVENT_NOT_FOUND 0
#define BAD_WORD_SPEC   1
#define BAD_WORD_SPEC   1
#define SUBST_FAILED    2
#define SUBST_FAILED    2
#define BAD_MODIFIER    3
#define BAD_MODIFIER    3
#define NO_PREV_SUBST   4
#define NO_PREV_SUBST   4
 
 
/* Possible definitions for history starting point specification. */
/* Possible definitions for history starting point specification. */
#define ANCHORED_SEARCH 1
#define ANCHORED_SEARCH 1
#define NON_ANCHORED_SEARCH 0
#define NON_ANCHORED_SEARCH 0
 
 
/* Possible definitions for what style of writing the history file we want. */
/* Possible definitions for what style of writing the history file we want. */
#define HISTORY_APPEND 0
#define HISTORY_APPEND 0
#define HISTORY_OVERWRITE 1
#define HISTORY_OVERWRITE 1
 
 
/* Some variable definitions shared across history source files. */
/* Some variable definitions shared across history source files. */
extern int history_offset;
extern int history_offset;
 
 
#endif /* !_HISTLIB_H_ */
#endif /* !_HISTLIB_H_ */
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.