author | marci |
Sat, 24 Apr 2004 12:44:41 +0000 | |
changeset 389 | 770cc1f4861f |
parent 253 | f45703336699 |
child 412 | 5d48b6773b73 |
permissions | -rw-r--r-- |
alpar@162 | 1 |
// -*- mode:C++ -*- |
alpar@162 | 2 |
|
alpar@162 | 3 |
#ifndef HUGO_INVALID_H |
alpar@162 | 4 |
#define HUGO_INVALID_H |
alpar@162 | 5 |
|
alpar@242 | 6 |
///\file |
alpar@242 | 7 |
///\brief Definition of INVALID. |
alpar@242 | 8 |
|
alpar@162 | 9 |
namespace hugo { |
alpar@162 | 10 |
|
alpar@162 | 11 |
/// Dummy type to make it easier to make invalid iterators. |
alpar@162 | 12 |
|
alpar@162 | 13 |
/// See \ref INVALID, how to use it. |
alpar@162 | 14 |
|
alpar@162 | 15 |
struct Invalid {}; |
alpar@162 | 16 |
|
alpar@162 | 17 |
/// Invalid iterators. |
alpar@162 | 18 |
|
alpar@162 | 19 |
/// \ref Invalid is a global type that converts to each iterator |
alpar@162 | 20 |
/// in such a way that the value of the target iterator will be invalid. |
alpar@184 | 21 |
|
alpar@184 | 22 |
// It is also used to convert the \c INVALID constant to the |
alpar@184 | 23 |
// node iterator that makes is possible to write |
alpar@184 | 24 |
|
alpar@165 | 25 |
//extern Invalid INVALID; |
alpar@162 | 26 |
|
klao@169 | 27 |
//const Invalid &INVALID = *(Invalid *)0; |
klao@169 | 28 |
const Invalid INVALID = Invalid(); |
alpar@162 | 29 |
|
marci@389 | 30 |
} //namespace hugo |
alpar@162 | 31 |
|
alpar@162 | 32 |
#endif |
alpar@162 | 33 |