Bonxai icon indicating copy to clipboard operation
Bonxai copied to clipboard

Add a simplistic C API for all unsigned data type widths as cell values to allow language interop

Open KitsuneAlex opened this issue 1 year ago • 5 comments

This would allow your library to be used in other languages which cannot directly interact with C++ through a simplistic C interface.

~~If you decide to merge this, it should be merged after my last fix PR.~~

Thanks for your excellent work on this project :)

KitsuneAlex avatar Dec 09 '24 01:12 KitsuneAlex

Lightly tested on Windows x64, Linux x64/arm64 and macOS x64/arm64. Also confirmed working with tools like jnih and Kotlin CInterop :)

KitsuneAlex avatar Dec 09 '24 03:12 KitsuneAlex

Hi.

Thanks for taking this initiative!

My suggestions are:

  • please no change in the namespace ("boncai"). Keep it "bonxai"
  • no alternative subdirectory. Instead, create a file called bonxai_core/include/bonxai/bonxai.h and add a target to the existing bonxai_core/CMaleLists.txt
  • remove changesto "serialize"

facontidavide avatar Dec 09 '24 12:12 facontidavide

Hi.

Thanks for taking this initiative!

My suggestions are:

  • please no change in the namespace ("boncai"). Keep it "bonxai"
  • no alternative subdirectory. Instead, create a file called bonxai_core/include/bonxai/bonxai.h and add a target to the existing bonxai_core/CMaleLists.txt
  • remove changesto "serialize"

Thanks for replying so quickly! Sounds good to me, will do :)

KitsuneAlex avatar Dec 09 '24 13:12 KitsuneAlex

This should do

KitsuneAlex avatar Dec 09 '24 13:12 KitsuneAlex

I commented on the other closed PR btw if you didn't get notified, the print was your original code, i removed it in an earlier PR which was a mistake from my end, that's why i added it back. Your serilization will likely break without it, which i didn't realize before.

KitsuneAlex avatar Dec 09 '24 13:12 KitsuneAlex