Re: Problems with DBI 1.617_903 on MSWin32

Dave Mitchell <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.dbi.sybase.devel
Message-ID <[email protected]>
On Wed, Feb 22, 2012 at 10:04:45AM +0000, Martin J. Evans wrote:
> DBI.xs(4291) : error C2275: 'SV' : illegal use of this type as an expression
>         C:\Perl\lib\CORE\perl.h(2243) : see declaration of 'SV'
...
> Lines 4291 and 4292 are:
>     MY_CXT_INIT;
>     (void)MY_CXT; /* avoid 'unused variable' warning */

Hopefully the diff below should fix it. Need declarations before code!

-- 
Gravity is just a theory; teach Intelligent Falling in our schools!
    http://www.theonion.com/content/node/39512


diff --git a/DBI.xs b/DBI.xs
index 144cfe5..3155c44 100644
--- a/DBI.xs
+++ b/DBI.xs
@@ -4290,9 +4290,10 @@ PROTOTYPES: DISABLE
 
 
 BOOT:
+    MY_CXT_INIT;
+
     (void)cv;
     (void)items; /* avoid 'unused variable' warning */
-    MY_CXT_INIT;
     (void)MY_CXT; /* avoid 'unused variable' warning */
     dbi_bootinit(NULL);
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.