<div dir="ltr"><div dir="ltr">On Mon, May 18, 2020 at 12:28 PM Levente Uzonyi <<a href="mailto:leves@caesar.elte.hu">leves@caesar.elte.hu</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Marcel,<br>
<br>
On Mon, 18 May 2020, Marcel Taeumel wrote:<br>
<br>
> Hi, there!<br>
> <br>
> In the #fields method of a new ExternalStructure, how can I express a pointer to another external structure?<br>
> <br>
> First, non-pointer works as expected:<br>
> ^ #( (other MyStruct) )<br>
> <br>
> Second, this just treats it as a void*, which returns a generic ExternalData:<br>
> ^ #( (other 'MyStruct*') )<br>
<br>
This is how it should be written. Does MyStruct exist when you're writing <br>
this method? If yes, is there a refence to that class in ExternalType's <br>
StructTypes class variable?<br>
<br>
Levente<br>
</blockquote><div><br></div><div><br></div><div>This is the correct answer. I missed the 'treats it as a void*' part.</div><div><br></div><div>The current FFI is very low-level. It tries to do as little magic as possible, meaning it may be necessary to still manually write a lot of the necessary accessors.</div><div><br></div><div>Also, we do not have a good story for 32/64 bits yet, I think. The same FFI code is unlikely to work on both.</div><div><br></div><div>- Vanessa - </div></div></div>