Generated on Mon Aug 25 11:35:51 2008 for Gecode by doxygen 1.5.6

Gecode::Int::Limits Namespace Reference
[Integer variables]


Detailed Description

Numerical limits for integer variables.

The integer limits are chosen such changing the sign is always possible without overflow.


Functions

void check (int n, const char *l)
 Check whether integer n is in range, otherwise throw out of limits with information l.
void check (double n, const char *l)
 Check whether double n is in integer range, otherwise throw out of limits exception with information l.

Variables

const int max = INT_MAX - 1
 Largest allowed integer value.
const int min = -max
 Smallest allowed integer value.


Function Documentation

void Gecode::Int::Limits::check ( int  n,
const char *  l 
) [inline]

Check whether integer n is in range, otherwise throw out of limits with information l.

Definition at line 41 of file limits.icc.

void Gecode::Int::Limits::check ( double  n,
const char *  l 
) [inline]

Check whether double n is in integer range, otherwise throw out of limits exception with information l.

Definition at line 47 of file limits.icc.


Variable Documentation

const int Gecode::Int::Limits::max = INT_MAX - 1

Largest allowed integer value.

Definition at line 99 of file int.hh.

Smallest allowed integer value.

Definition at line 101 of file int.hh.