From: <pa...@id...> - 2005-02-16 03:41:11
|
Hi, I came across ZooLib while looking for a thread safe smart pointer, but I`m having a bit of trouble compiling under VS 2005. The compiler didn't like inline functions outside of class definitions in .hpp files, or the inline assembly, so I moved things around a bit to see if I could just get it working enough to see how good these ZRefs are. The snag now is that trying to use a ZRef with the dumb versions of the code causes infinite recursion: .exe!ZAtomic_Add(ZAtomic_t * inValueAddress=0x00a879c4, int inParam=1) Line 405 C++ .exe!ZMutexNR::Acquire() Line 986 + 0xe bytes C++ .exe!ZAtomic_Add(ZAtomic_t * inValueAddress=0x00a879c4, int inParam=1) Line 405 C++ .exe!ZMutexNR::Acquire() Line 986 + 0xe bytes C++ .exe!ZAtomic_Add(ZAtomic_t * inValueAddress=0x00a879c4, int inParam=1) Line 405 C++ .exe!ZMutexNR::Acquire() Line 986 + 0xe bytes C++ .exe!ZAtomic_Inc(ZAtomic_t * inValueAddress=0x0744014c) Line 449 C++ .exe!ZRefCounted::sIncRefCount(ZRefCounted * inObject=0x07440148) Line 35 + 0xc bytes C++ .exe!ZRef<Ng::Action>::operator=(Ng::Action * other=0x07440148) Line 189 + 0x9 bytes C++ I went back to trying to get the inline assembly working in ZAtomic.cpp, changing asm{ to __asm{, but it fails on lines such as: lock xadd [edx], inParam, with error C2415: improper operand type. The compiler compiles my SSE code OK, but I`m not that knowledgable on assembly. I`m getting an error trying to browse the CVS online, is there a more recent version of ZAtomic, or any other tips for using ZooLib and VS 2005? I also noticed an old post on using ZooLib for PhotoShop plugins, was any progress ever made? Thanks, Paul Nolan, CEO Idruna Software Inc. http://www.idruna.com |