upvote
> Or you're writing for a platform where you have no choice (most microcontrollers for example).

I don't get this in particular. All of these devices have C, which seems like a better fit for the problems you'd likely have on a platform that's small or obscure enough that it hasn't got something nicer than C++

reply
In places where you can use C you can just ask easily use C++. It has a number of nice ergonomic improvements that make it a better option than C, though you would typically opt out of exceptions, RTTI, and maybe the standard library.
reply
For most microcontrollers you'd want to use today (ARM and RISC-V mostly, Xtensa or AVR if you like pain) you can just use Rust.

For anything weirder than that (PIC?) where Rust is no option, it's not like you have no choice either: You can just pick C.

reply
> You want to use Qt

But isn't using Qt like learning a whole new layer of language on top of C++, the meta compiler, signal/slot system etc and then Qt have its own set of standard classes like QString (instead of using std::string)

reply
C++32’s std::ui will solve that.
reply
Sure, but Qt (at least QtWidgets) is still really good, even if it is aging quite badly at this point.

The signal/slot system actually doesn't need MOC anymore, and the custom container classes are pretty obvious.

That said I think some Rust GUI frameworks are finally starting to mature. I quite like gpui-kit (formerly gpui-component). Maybe not as easy to use as Qt but it doesn't matter so much now with AI.

reply