[PyKDE] SIP 3.10 problems

Claus, Richard claus at SLAC.Stanford.EDU
Fri Feb 27 22:19:00 GMT 2004


Thanks, Phil.  The 20040218 snapshot seems to have taken care of it.

I presume the various

cl : Command line warning D4024 : unrecognized source file type 'WIN32', object file assumed
cl : Command line warning D4027 : source file 'WIN32' ignored

and 

LINK : warning LNK4199: /DELAYLOAD:comdlg32.dll ignored; no imports found from comdlg32.dll
LINK : warning LNK4199: /DELAYLOAD:oleaut32.dll ignored; no imports found from oleaut32.dll
LINK : warning LNK4199: /DELAYLOAD:winmm.dll ignored; no imports found from winmm.dll
LINK : warning LNK4199: /DELAYLOAD:wsock32.dll ignored; no imports found from wsock32.dll
LINK : warning LNK4199: /DELAYLOAD:winspool.dll ignored; no imports found from winspool.dll

build messages are benign as well?

	Thanks,
		Ric


> -----Original Message-----
> From: Phil Thompson [mailto:phil at riverbankcomputing.co.uk] 
> Sent: Friday, February 27, 2004 11:33 AM
> To: pykde at mats.imk.fraunhofer.de
> Cc: Claus, Richard; 'pykde at mats.imk.fraunhofer.de'
> Subject: Re: [PyKDE] SIP 3.10 problems
> 
> 
> On Friday 27 February 2004 19:14, Claus, Richard wrote:
> > Windows:
> > Microsoft Development Environment 2003, version 7.1.3088
> > Microsoft Visual C++ .NET   69462-270-0000007-18739
> >
> > C:\test>sip -V
> > 3.10 (3.10-171)
> >
> > Excerpted from my code:
> > OSWtimeContribution.h:
> > class DLL_EXPORT_API OSWtimeContribution
> > {
> > public:
> >   OSWtimeContribution()  {}
> >   ~OSWtimeContribution() {}
> >
> >   void timebase(unsigned* tb) const { tb[0] = _timebase[1];
> >                                       tb[1] = _timebase[0]; }
> >
> > private:
> >   unsigned _timebase[2];
> > };
> >
> > OSWtimeContribution.sip version 1:
> > %ModuleHeaderCode
> > #include "OSWtimeContribution.h"
> > %End
> >
> >
> > class OSWtimeContribution
> > {
> > public:
> >   OSWtimeContribution();
> >   ~OSWtimeContribution();
> >
> >   void timebase(unsigned* /*tb*/)  const;
> > %MemberCode
> >     OSWtimeContribution* sipCpp;
> >     unsigned*            a0;
> >
> >     if (sipParseArgs(&sipArgsParsed,sipArgs,"mi",
> > sipThisObj,sipClass_OSWtimeContribution,&sipCpp, &a0)) {
> >       Py_BEGIN_ALLOW_THREADS
> >       sipCpp -> timebase(a0);
> >       Py_END_ALLOW_THREADS
> >     }
> > %End
> > };
> >
> > sip -w gives:
> > sip: Warning: ../sip/OSWtimeContribution.sip:23: %MemberCode is 
> > deprecated, please use %MethodCode instead
> >
> > Changing %MemberCode to %MethodCode gives a crash:
> > The instruction at "0x00404d64" refrenced memory at 
> "0x00000000".  The 
> > memory could not be "read".
> >
> > Following a suggestion from Jim Bublitz, I think the 
> following should 
> > work: OSWtimeContribution.sip version 2: %ModuleHeaderCode
> > #include "OSWtimeContribution.h"
> > %End
> >
> >
> > class OSWtimeContribution
> > {
> > public:
> >   OSWtimeContribution();
> >   ~OSWtimeContribution();
> >
> >   void timebase(unsigned* /Out/)  const;
> > };
> >
> > This gives the same crash at 0x00404d64.
> >
> > Changing /Out/ to /In/ above allows "successful" compilation, but 
> > seems wrong.  Does the Out/In qualifier refer to the 
> pointer or what 
> > it points to?
> 
> /In/ means the pointer points to a value being passed to the function.
> 
> /Out/ means the function will return a value via the pointer.
> 
> /In,Out/ means both.
> 
> The default in this case is /Out/.
> 
> It would be worth you trying a current snapshot if you still 
> have problems as 
> there have been fixes in this area.
> 
> > Also, in the full project I get lots of the following from sip 
> > generated code during "successful" compilation:
> > c:\online\ebf\vs.net2003\sipebftkrcontribution.cpp(71) : warning 
> > C4700: local variable 'sipRes' used without having been initialized
> >
> > c:\online\ebf\vs.net2003\sipebfaemheader.cpp(64) : warning C4700: 
> > local variable 'a0' used without having been initialized
> >
> > c:\online\ebf\sipebflatcontributioniterator.cpp(68) : 
> warning C4715: 
> > 'sipLATcontributionIterator::EBF' : not all control paths return a 
> > value
> 
> These are benign. If you used SIP v4 you shouldn't see any warnings.
> 
> Phil
> 




More information about the PyQt mailing list