SWI-Prolog / contrib-swiplcs

Interface from C# to SWI-Prolog
http://www.lesta.de/Prolog/SwiPlCs/Generated/Index.html
24 stars 10 forks source link

SwiPICs updated to support SWI-Prolog Version 8.0.3-1 32bit and 64bit #7

Closed abaffa closed 5 years ago

abaffa commented 5 years ago

Updated sizeOfIostream in LibPI.cs to support libswipl.dll from SWI-Prolog Version 8.0.3

Version 64Bit

const int sizeOfIostream = 256;

Version 32Bit

const int sizeOfIostream = 160;

JanWielemaker commented 5 years ago

Thanks. Guess it will also run on 8.1.x. Is there a sensible way to get rid of these structure size and offset dependencies? Although the layout and size is supposed to be fairly stable it does accidentally change between major versions or minor versions in the development versions.

I guess the options are to either provide functions with non-struct arguments or a runtime function that will provide this info, no? If this is the only structure for which we need to do this I'm in favor of finding a proper maintainable solution.