18 ms·
Does Qt still do that thing where they reimplement a lot of the C++ standard components like Vector? I remember years ago having problems with their reimplemen
by jo_ 12y ago
Does Qt still do that thing where they reimplement a lot of the C++ standard components like Vector? I remember years ago having problems with their reimplementation and wonder how much that's changed.
- FigBug 12y agoYup, QList, QVector, QString. There are a lot of reimplementations. I tend to find them a lot easier to use than the C++ counterparts. What type of problems were you having?
- heeen 12y agoQString is a proper unicode-aware string with conversions to many character codecs. It doesn't really compare to std::string.
- joshvm 12y agoI agree. QList is great, it's got very straightforward methods and it's more than fast enough.
- jo_ 12y agoNothing impossible -- just integration with the standard library algorithms and some older source code I don't want to modify. It's less difficulty and more a matter of laziness.
- blub 12y agoThe "QTL" still exists, yes. One can use the STL in their code and convert when interacting with the Qt framework (for a price paid in performance)
- eduardordm 12y agoYes, keep in mind that some platforms where QT runs do not have the library implemented, have suboptimal performance or is missing functionality. Also, binary compatibility is a big plus on QT. A nice read about it: http://blog.codeimproved.net/posts/qtl-stl.html http://blog.codeimproved.net/posts/qtl-stl.html
- superfunc 12y agoYeah. iirc, most of their data structures are COW which can be nice, depending on what your looking for. And, as others have mentioned, they often have a simpler, if less generic, API to them.
- skrebbel 12y agoYeps. It sucks when integrating libraries that use the STL, but otherwise they're actually much nicer in many ways. Simpler to use, at the cost of one extra pointer dereference - worth the reduced complexity and error-prone-ness, in many cases.
- pjmlp 12y agoYes they do. This is what happens when you need to support a myriad of compilers and OS, with different levels of language support and bugs.