4 ms·
It seems to be a nice project but they should remove "C++" from the name since both languages have nothing in common anymore, especially the use of smart pointe
by JTyQZSnP3cQGa8B 4y ago
It seems to be a nice project but they should remove "C++" from the name since both languages have nothing in common anymore, especially the use of smart pointers and Boost.Asio compared to "malloc and socket" that is used in the book.
- hewlett 4y agoYou can still use raw pointers and sockets in C++, which the code examples provided in the book do
- JTyQZSnP3cQGa8B 4y agoI agree but no one calls this C++ anymore especially since C++14/17, and I fail to see why you would use a C++ compiler for such a code.
- gpderetta 4y agoWell, if you are implementing something like ASIO, and of course c++ is a good language for that, you'll be dealing with sockets directly.
- deleted 4y ago[deleted]
- _gabe_ 4y ago> I agree but no one calls this C++ anymore especially since C++14/17 I do. Who's to say if you use C++, thou shalt always use: smart pointers, move semantics, OOP, templates, and more. Also, you're discounting a very large and very real industry of people writing code for embedded hardware that doesn't necessarily have the luxurious memory resources modern devices have. Why could I ever possibly want to use C++ if I don't want to use smart pointers and OOP and all that other stuff? Well, generic type safety is very nice. Templates don't exist in C. Constexpr and references are also quite nice. They allow me to annotate my code to make my intentions clearer. Operator overloading is also insanely helpful at times. Matrix/vector math is so much nicer to write/read using mathematical operators instead of function calls everywhere. This also isn't possible in C. Anyways, don't go making claims that if somebody doesn't use a language exactly the same way you do, then they're using it wrong. Especially when it's a language as massively overengineered as C++. There are plenty of reasons to prefer a subset of C++ to C, and plenty of valid reasons to prefer to use C instead of dealing with the complexities of C++.
- batty_alex 4y agoThe article doesn’t use any C++ features, though. It’s straight C code. Pretty sure that’s what they meant
- Arelius 4y agoI'm starting to understand there are clearly 2 different worlds, if you live in one where C++ assumes the use of smart pointers, or especially Boost. In the C++ world I live/work Boost is avoided like the plague. I always wondered how Boost continues to exist, but it seems in certain communities it's held up as a standard to strive for.
- mianos 4y agoI think in the even more modern world, there is also the use of post C++17 smart pointers and still avoiding boost if at all possible. Personally I have grown a little softer on it now that adding boost does not take an application that took a few minutes to build to one that takes an hour.
- stonemetal 4y agoMore than half a dozen Boost libraries have made their way to the standard. Boost continues to exist because there is large overlap with the standards committee and they use it as a staging ground to try out new ideas before they are standardized.