On Wednesday, 26 February 2014 at 11:21:37 UTC, bearophile wrote:
Szymon Gatner:

That would be just it:

import dchip.all;

void main()
{
 cpBody* bodies[];
 auto b = cpBodyNew(0, 0);
 bodies ~= b;
}

where dchip is pulled using dub. As described earlier, wrapping cpBody* in another struct or Tuple works.

Now you have to remove all imports from the code :-)

Bye,
bearophile

I just pulled cpBody struct definition on top of main() and now it compiles... So I guess this means that when importin main() does not see full cpBody struct definition? But why does that even matter? It is just pointers being stored.

Reply via email to