Thanks Doug and john.  I appreciate your help.  I will look at this again over 
the weekend.

Mike.

----- Original Message ----
From: skaller <[EMAIL PROTECTED]>
To: Doug Baskins <[EMAIL PROTECTED]>
Cc: [email protected]; Mike Eynon <[EMAIL PROTECTED]>
Sent: Saturday, July 14, 2007 12:01:43 AM
Subject: Re: CheckDupLines not compiling with gcc


On Fri, 2007-07-13 at 23:47 -0700, Doug Baskins wrote:
> John:
> 
> Sorry, I miss-diagnosed the problem,
> the problem cast essentially is: 
> 
>        unsigned long * abc = (void *)(~0UL);
> 
> Which means storing a void pointer into a word pointer is illegal.

Implicit conversions FROM void* in C++ are ALL disallowed
(except to void const* of course).

The code is above is a hard error in C++. You must write:

       unsigned long * abc = (unsigned long*)(void *)(~0UL);

if you want it to work. This is different to C, C allows
implicit conversions FROM void*.

So this has nothing to do with void*<-->integer casts.

-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


       
____________________________________________________________________________________
Choose the right car based on your needs.  Check out Yahoo! Autos new Car 
Finder tool.
http://autos.yahoo.com/carfinder/

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Judy-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/judy-devel

Reply via email to