1228060Sbapt/* Inline Functions for keyword-list.{h,cc}.
2228060Sbapt
3228060Sbapt   Copyright (C) 2002-2003 Free Software Foundation, Inc.
4228060Sbapt   Written by Bruno Haible <bruno@clisp.org>.
5228060Sbapt
6228060Sbapt   This file is part of GNU GPERF.
7228060Sbapt
8228060Sbapt   GNU GPERF is free software; you can redistribute it and/or modify
9228060Sbapt   it under the terms of the GNU General Public License as published by
10228060Sbapt   the Free Software Foundation; either version 2, or (at your option)
11228060Sbapt   any later version.
12228060Sbapt
13228060Sbapt   GNU GPERF is distributed in the hope that it will be useful,
14228060Sbapt   but WITHOUT ANY WARRANTY; without even the implied warranty of
15228060Sbapt   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16228060Sbapt   GNU General Public License for more details.
17228060Sbapt
18228060Sbapt   You should have received a copy of the GNU General Public License
19228060Sbapt   along with this program; see the file COPYING.
20228060Sbapt   If not, write to the Free Software Foundation, Inc.,
21228060Sbapt   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
22228060Sbapt
23228060Sbapt/* -------------------------- Keyword_List class --------------------------- */
24228060Sbapt
25228060Sbapt/* Access to first element of list.  */
26228060SbaptINLINE Keyword *
27228060SbaptKeyword_List::first () const
28228060Sbapt{
29228060Sbapt  return _car;
30228060Sbapt}
31228060Sbapt
32228060Sbapt/* Access to next element of list.  */
33228060SbaptINLINE Keyword_List *&
34228060SbaptKeyword_List::rest ()
35228060Sbapt{
36228060Sbapt  return _cdr;
37228060Sbapt}
38228060Sbapt
39228060Sbapt/* ------------------------- KeywordExt_List class ------------------------- */
40228060Sbapt
41228060Sbapt/* Access to first element of list.  */
42228060SbaptINLINE KeywordExt *
43228060SbaptKeywordExt_List::first () const
44228060Sbapt{
45228060Sbapt  return static_cast<KeywordExt*>(_car);
46228060Sbapt}
47228060Sbapt
48228060Sbapt/* Access to next element of list.  */
49228060SbaptINLINE KeywordExt_List *&
50228060SbaptKeywordExt_List::rest ()
51228060Sbapt{
52228060Sbapt  return *reinterpret_cast<KeywordExt_List**>(&_cdr);
53228060Sbapt}
54