Source: whatsup/ItemCmp.h
|
|
|
|
/***************************************************************************
ItemCmp.h - description
-------------------
begin : Don Jun 6 2002
copyright : (C) 2002 by
email :
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef _ItemCmp_h_
#define _ItemCmp_h_
#include
/*
* The following code should be platform independant.
*/
inline int cmp(int a, int b)
{
return (a < b ? -1 : (a > b ? 1 : 0));
}
inline int cmp(unsigned int a, unsigned int b)
{
return (a < b ? -1 : (a > b ? 1 : 0));
}
inline int cmp(long a, long b)
{
return (a < b ? -1 : (a > b ? 1 : 0));
}
inline int cmp(double a, double b)
{
return (a < b ? -1 : (a > b ? 1 : 0));
}
#endif
| Generated by: andreas on linux on Sat Jun 15 19:28:49 2002, using kdoc 2.0a53. |