<div dir="ltr">Thanks Bulat! So since we are &quot;talking&quot; ;^) .... is there a function already in Foreign that will allow me to ...<br><br>[a] -&gt; Ptr (Ptr ()) i.e. map a list of type &quot;a&quot; to an array of ptrs of type &quot;a&quot;?<br>
<br>Kind regards, Vasili<br><br><div class="gmail_quote">On Fri, Aug 1, 2008 at 12:53 AM, Bulat Ziganshin <span dir="ltr">&lt;<a href="mailto:bulat.ziganshin@gmail.com">bulat.ziganshin@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello Vasili,<br>
<div class="Ih2E3d"><br>
Friday, August 1, 2008, 9:08:05 AM, you wrote:<br>
<br>
&gt; &nbsp;&nbsp;&nbsp;&nbsp; Is a (Ptr (Ptr a)) a polymorphic representation of an array of<br>
&gt; pointers of type &quot;a&quot;? I want to pass an array of pointers to a C function.<br>
<br>
</div>use Ptr (Ptr ())<br>
<br>
Ptr () &nbsp;in haskell is like void* in C, it&#39;s used to represent pointer<br>
to arbitrary type. you can use castPtr to cast pointers between different<br>
types<br>
<font color="#888888"><br>
<br>
--<br>
Best regards,<br>
&nbsp;Bulat &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;mailto:<a href="mailto:Bulat.Ziganshin@gmail.com">Bulat.Ziganshin@gmail.com</a><br>
<br>
</font></blockquote></div><br></div>