5 ms·
I agree 100% with second point. I enjoy writing c++11/14 and it's not my primary language. 10 years ago i would say no to c++ but today it's like writing in dif
by lossolo 11y ago
I agree 100% with second point. I enjoy writing c++11/14 and it's not my primary language. 10 years ago i would say no to c++ but today it's like writing in different language.
Qt is another huge argument why i use C++, there is no alternative (or i don't know any other cross-platform framework as good and mature as Qt is).
- truncate 11y agoHow about Qt bindings to other languages? Last I checked for Python (like 4 years) ago, the biggest problem I had was with licence (GPL). But yeah, compared to Python, using C++ also gives me system threads which might come handy every now and then for CPU intensive stuff.
- lossolo 11y agoI don't know about python bindings, but i was looking at Go bindings. Anyway for me it feels natural to just use modern c++ with Qt, it works for me, i do not feel like i am loosing productivity.
- zanny 11y agoThe problem with the Python Qt bindings, in my experience, is that PyQt is not... pythonic. I like Pythonic things, like Flask, over less-Pythonic alternatives, like Django. At least in principal. And yes, I know Django has gotten better about it over the years. I need to try a new project in it at some point, especially considering Flask's atrophy. But PyQt is not so much a binding layer as just Qt in Python, literally. It has to be some kind of semantic offense though, since I have no problem writing Qt C++ to begin with. It is just the language and style of the API itself favors C++ because thats what it is made for. QML and Python, on the other hand? Lovely. If it didn't depend on all of PyQt to just start up a QML program and signaling into / out of it, I'd be all over that idea. Which is probably where I am super interested on the Rust front. qmlrs showed a lot of promise last year, and while the project seems to be suffering from a lack of contributions as of late, someone will eventually pick up the reigns - I do not think any other GUI framework is even close to appropriate for Rust to begin with anyway.
- cobookman 11y ago+1000. there's std::async, and std::promise, with futures lambdas and smart pointers. I really do feel like c++ is a new language. I will mention that it still lets you shoot yourself in the foot. However now you get to choose when you'd like to prevent shooting yourself in the foot.
- cobookman 11y ago+1000. there's std::async, and std::promise, with futures lambdas and smart pointers. I really do feel like c++ is a new language. I will mention that it still lets you shoot yourself in the foot. However now you get to choose when you'd like to prevent shooting yourself in the foot.
- joezydeco 11y ago...I don't know any other cross-platform framework as good and mature as Qt is There isn't. I've been looking for twenty years. Qt is the only platform I'll use for embedded GUI development.
- holmak 11y agoI tried to learn "modern" C++ style, and watched many, many videos from cppcon, but I just don't feel like I understand how to do it. I started a C++ project, #included <vector> and all the rest, and tried to do things the way the experts recommend, but I had no confidence that I was doing any of it right. I know all the copying and moving and whatnot is supposed to "just work", but as far as I can tell, there's no easy way to verify that your program is doing what you intend. There also aren't any compact guidelines -- "follow these N simple rules and the STL won't explode!". With most other languages, I can at least think through the program to figure out if it is going to do what you intend, but the way that the STL is implemented to support all the modern C++ behavior requires a brain the size of a planet to understand. I'm sure Stroustrup and the committee can write Modern C++, but I sure can't. Not with any confidence, anyway.
- lossolo 11y agoNo one said that C++ is easy, you need to teach yourself about pointers even if you will not use them so often, because almost everything under the hood is connected to pointers in some way. You need to learn the language. Watching video from ccpcon is not the way you will learn C++. Read book from Stroustrup about C++.
- holmak 11y agoI don't have any trouble with pointers. I can understand C programs just fine. But Modern C++, as the evangelists love to point out, is specifically about avoiding raw pointers in favor of smart pointers, value semantics, etc. That's the stuff that I find difficult to use. I did buy Stroustrup's post-C++11 book, "A Tour of C++", which is supposed to be the compact "how to do Modern C++". It provides tips, but as I mentioned above, I did not find it comprehensive enough. Terse recommendations like "Prefer returning by value" may be great small-scale recommendations, but they don't explain how the big picture is supposed to come together.
- lossolo 11y agoYou should watch those cppcon again, because Stroustrup and Herb are saying there many times that smart pointers are NOT should be use instead of raw pointers. Use smart pointers where It's about ownership. You should watch this video: https://www.youtube.com/watch?v=1OEu9C51K2A https://www.youtube.com/watch?v=1OEu9C51K2A