diff options
Diffstat (limited to 'contrib/groff/src/roff/troff/symbol.h')
-rw-r--r-- | contrib/groff/src/roff/troff/symbol.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/contrib/groff/src/roff/troff/symbol.h b/contrib/groff/src/roff/troff/symbol.h index 88e0fff..5b7c9b1 100644 --- a/contrib/groff/src/roff/troff/symbol.h +++ b/contrib/groff/src/roff/troff/symbol.h @@ -1,5 +1,5 @@ // -*- C++ -*- -/* Copyright (C) 1989, 1990, 1991, 1992 Free Software Foundation, Inc. +/* Copyright (C) 1989, 1990, 1991, 1992, 2002 Free Software Foundation, Inc. Written by James Clark (jjc@jclark.com) This file is part of groff. @@ -36,10 +36,12 @@ public: int operator !=(symbol) const; const char *contents() const; int is_null() const; + int is_empty() const; }; extern const symbol NULL_SYMBOL; +extern const symbol EMPTY_SYMBOL; inline symbol::symbol() : s(0) { @@ -70,4 +72,9 @@ inline int symbol::is_null() const return s == 0; } +inline int symbol::is_empty() const +{ + return s != 0 && *s == 0; +} + symbol concat(symbol, symbol); |