man/l_roff-char.7.in: fix Bernd Warken (Dave Kemper, Werner Lemberg)..
[s-roff.git] / include / errarg.h
bloba1a73dcd38a813840dd6d6271d4e0b3a96f4d514
1 /*@
2 * Copyright (c) 2014 - 2017 Steffen (Daode) Nurpmeso <steffen@sdaoden.eu>.
4 * Copyright (C) 1989 - 1992, 2002 Free Software Foundation, Inc.
5 * Written by James Clark (jjc@jclark.com)
7 * This is free software; you can redistribute it and/or modify it under
8 * the terms of the GNU General Public License as published by the Free
9 * Software Foundation; either version 2, or (at your option) any later
10 * version.
12 * This is distributed in the hope that it will be useful, but WITHOUT ANY
13 * WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15 * for more details.
17 * You should have received a copy of the GNU General Public License along
18 * with groff; see the file COPYING. If not, write to the Free Software
19 * Foundation, 51 Franklin St - Fifth Floor, Boston, MA 02110-1301, USA.
21 #ifndef _ERRARG_H
22 #define _ERRARG_H
24 class errarg
26 enum { EMPTY, STRING, CHAR, INTEGER, UNSIGNED_INTEGER, DOUBLE } type;
27 union {
28 const char *s;
29 int n;
30 unsigned int u;
31 char c;
32 double d;
35 public:
36 errarg();
37 errarg(const char *);
38 errarg(char);
39 errarg(unsigned char);
40 errarg(int);
41 errarg(unsigned int);
42 errarg(double);
43 int empty() const;
44 void print() const;
47 extern errarg empty_errarg;
49 extern void errprint(const char *,
50 const errarg &arg1 = empty_errarg,
51 const errarg &arg2 = empty_errarg,
52 const errarg &arg3 = empty_errarg);
54 #endif // _ERRARG_H
55 // s-it2-mode