POV-Ray : Newsgroups : povray.off-topic : Random C craziness : Re: Random C craziness Server Time
7 Sep 2024 05:11:40 EDT (-0400)
  Re: Random C craziness  
From: Fredrik Eriksson
Date: 24 Jul 2008 13:19:46
Message: <op.ues3q8fh7bxctx@e6600>
On Thu, 24 Jul 2008 14:24:51 +0200, Vincent Le Chevalier  
<gal### [at] libertyallsurfspamfr> wrote:
> I was thinking the same, but I can't seem to find the right type  
> definition to make it work without casting to and from void*... Which is  
> apparently illegal  
> (http://www.parashift.com/c++-faq-lite/pointers-to-members.html#faq-33.8)

It is illegal because a 'void *' is a data pointer, not a function pointer.

On a related note, we do not know if the original code was supposed to be  
standards-compliant or not, nor if it was supposed to be C or C++.


> Here's what I ended up with:
[...snipped...]

The "right" way to do it, assuming C++:
http://www.gotw.ca/gotw/057.htm



-- 
FE


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.