Some mod's to cope with MSVC's poor C++ support

This commit is contained in:
Andrew Johnson
2001-02-14 20:13:36 +00:00
parent 2a763a57ae
commit 93aa11d2f6

View File

@@ -69,7 +69,7 @@ public:
void reset();
private: // Data
static const int blocksize = 256;
enum {blocksize = 256}; // Poor man's const int, for MSVC++
epicsListNode _node[blocksize];
};
@@ -134,12 +134,23 @@ inline void epicsListLink::swap(epicsListLink& node) {
// epicsListNode
// Disable spurious warnings from MSVC
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable:4355)
#endif
inline epicsListNode::epicsListNode() :
_next(this + 1), _prev(0), payload(0) {}
inline epicsListNode::epicsListNode(int) :
_next(this), _prev(this), payload(0) {}
#ifdef _MSC_VER
#pragma warning(pop)
#endif
inline bool epicsListNode::hasNext() const {
return (_next != this);
}