// Exception.cpp
// Exception is called when the condition is not satisfied.
// The functions remove and getfront uses this exception
// function to alarm the user of errors.  
// For remove(), when the list is already empty, exception
// alarms the user that the list is already empty.
// Basically, the same goes for getFront().  If a list is 
// empty and get front  is used, then error message is displayed.

#include "Exception.h"
#include <stdlib.h>
#include <iostream.h>

void
EXCEPTION( int Condition, const char *ErrMsg )
{
    if( Condition )
    {
        cerr << "Exception: " << ErrMsg << endl;
        abort( );
    }
}
