Google Search

Google Search Results

Showing posts with label vclutils.h dateutils.hpp compiler warnings VCL. Show all posts
Showing posts with label vclutils.h dateutils.hpp compiler warnings VCL. Show all posts

Tuesday, September 9, 2008

vclutils.h

In some of my other blogs I reference this include file. It isn't much, just a way to avoid compiler warnings when using dateutils.hpp, here you go... include this file instead of dateutils.hpp directly:

----------- vclutils.h ----------

#ifndef VCLUTILS_H
#define VCLUTILS_H 1

// Use this header instead of directly to avoid compiler warnings (see below)

#include

// Because "dateutils.hpp" includes a bunch of static const variables
// (also from math.hpp) we have to do this to get rid of warnings.
namespace DoNotUse
{
static const Extended eliminateWarnings = NaN + Infinity + NegInfinity +
OneHour + OneMinute + OneSecond + OneMillisecond + MinSingle + MaxSingle +
MinDouble + MaxDouble + MinExtended + MaxExtended + MinComp + MaxComp;
}

#endif // don't nest header