r/cpp • • Apr 02 '26

Announcing mrbind, an automatic C/C#/Python binding generator for C++

https://holyblackcat.github.io/blog/2026/04/02/announcing-mrbind.html
30 Upvotes

26 comments sorted by

View all comments

Show parent comment

2

u/holyblackcat Apr 03 '26

I see. We had at least one confused Python user who modified an object returned by a const ref and got a crash, so I went out of my way to have const-correctness in the other backends (C and C#).

The Python backend (which was implemented first) lacks it, so we copy objects returned by const ref (by default) to prevent those modifications.