[Interest] Qt API annoyances: where to log/discuss?

Jason H jhihn at gmx.com
Wed Oct 31 22:30:26 CET 2018

I don't disagree with you, but I have a variety of developers that work with me/read/modify my code, and they are  of varying levels of proficiency (none are actual C++ programmers by choice) (Java is their main language). I want to make things as friendly and obvious and for them (and guiltily, myself). The nice thing is that when the C++ std level of detail is needed it is there. But 99% of the time we have no need for it to be the absolute best performant code. I understand API creators have that requirement, but application developers usually do not. Maybe C++ isn't the right language, but there's so much Qt does right over all the other options we have.

I will continue to increase my proficiency in C++, but this is my personal commitment. I cannot demand the same for the others. 

> Sent: Wednesday, October 31, 2018 at 5:19 PM
> From: "Jérôme Godbout" <godboutj at amotus.ca>
> To: "Jason H" <jhihn at gmx.com>, "giuseppe.dangelo at kdab.com" <giuseppe.dangelo at kdab.com>
> Cc: "interest at qt-project.org" <interest at qt-project.org>
> Subject: RE: [Interest] Qt API annoyances: where to log/discuss?
> All those back_inserter() and C++0xXY template make our life easier in the end, I strongly suggest you do learn them, they can make very generic code with SFINAE that most other language will have hard time to accomplish with the same final level of performance. It's a good balance of quantity of code vs speed. The draw back, is the learning curve and the readability that are hideous.
> I agree there is way too much boiler plate for C++ template syntax, but you can design some helper to simplify your SFINAE or other template usage. back_inserter() for example let you make an algo that work with any type of container that will append data, no matter what that container can be, you can even make your own container as long as you provide the push_back() function.
> Why use back_inserter over direct push_back? Because some algo like copy operate on iterator and don't need to be rewritten with a push_back version to work, as simple as that. The mor you will stay close to the iterator and the standard, the easier it will be to code with it.

More information about the Interest mailing list