Closed JROB774 closed 1 month ago
Oh, interesting - I'd somehow never actually spotted that but you're entirely right. Fixing that in the general case would be quite fiddly but there's only a handful by the looks of it so some special-case adjustments should do the trick. I'll try and put something in shortly to sort those out and report back here when it's done. Thanks for the report!
OK, I've added a simple fix to make those use the correct functions, and also renamed the macros to CIM_ALLOC
and CIM_FREE
so as to avoid compiler warnings when compiling code that also references imgui.h
.
Hopefully that fixes things for you - if run into any other problems please just let me know.
Thanks again for the report!
Nice, thanks for looking into that, the changes look good! Just a heads up that I spotted the IMGUI_CHECKVERSION
is still using the C++ syntax. I am not using that macro, so didn't flag/notice it initially, but it might be worth just fixing that one up as well for completeness. Other than that, I'm happy for the issue to be closed -- thanks again for the quick fix!
Good point, I'd overlooked that one - I've fixed it now too. Thanks!
Awesome, I'll close the issue now - thanks again. :)
Whilst working on a custom ImGui backend in C, I noticed that macros defined in
cimgui.h
expand out to use the original C++ syntax, e.g:Rather than the expected C syntax: