Posts by Michael De Lang
How else he's going to teach people why c++ strings are how they are? It solved a rail pain and will prevent pain for you once you understand. Otherwise, abusing ats::string will lead you to days of debug hell...
Not to mention having different member variables depending on the CRTP param...
A conversion allocates and does some "real" work for some definition of "real". Casts, especially c style casts, are just sprinkles of magic fairy dust to make the compiler treat something as a different type. Sometimes that fairy dust is actually demon dust though.
Yeah, especially because it's mostly tailor made for Google's workflow. Haven't been able to try it, but perhaps github.com/uatuko/grpcxx is slightly easier to use?
If you're writing your game in ASM, I have bad news for you.
You aren't a game dev.
You aren't making anything.
You're relying on a cheap tool to make the game for you, so you can feel proud.
Come back when you've written a game in hardware logic gates... then we'll talk.
Unfortunately I see a lot of global mutable state in embedded projects. Kind of like errno, but custom. Having independent parts of the code react or not depending on that leads to having at least half a working system in some cases.
There's Conan and vcpkg. But before I get your hopes up, they're nowhere near as good as cargo.
With WAL, synchronous=normal and order-dependent execution, I really wonder if it's use is justified. Either the use-case is one where'd one be better of using postgresql/mysql/etc or in a single user use case, I only see it as an overkill function that adds overhead.
If you're able to use c++23: github.com/stephenberry...
This library is so much more convenient than any other to use and the performance is one of the best (jsonifier might beat it depending on use case)
Learning is fun, but c++ (especially on windows) is a marathon of masochism. Whether you enjoy such a thing or not is up to you. It will end up giving you a greater mastery of programming though, as you will have to touch on all the things that make a computer work.
This seems like such a waste of engineering effort for practically 0 gains... I question the benefit of the asynchronous API too.
Std variant should come pretty close?
Wow. You'd think that after ten years of programming c++ I'd have noticed this. But no, TIL.
🎉
🎉
A good out of the box thinking blog post on the current safety in c++ dichotomy: cor3ntin.github.io/posts/profil...
It is one of the more difficult tools to use yes :(
Does anyone have any recommendations on organizational learning? Double-loop learning and so on. #organizationallearning #managementbooks #learningfromfailure #books
The AI hype is so strong that Microsoft published an article that looks like it was written by an LLM. I keep saying it to whoever wants to listen, the current generation AI is making software development worse. jadarma.github.io/blog/posts/2...
Link missing :(
The enshittification continues. www.baldurbjarnason.com/2024/the-det...
Story-time: C++, bounds checking, performance, and compilers -Coding in Old Entish
chandlerc.blog/posts/2024/11/story-time...
#frombsky
Original->
And then in your c code you cast it back and forth.
This is great for learning making your own bindings, however, there are usually libraries that make c++ interop more seamless by hiding the gory details. F.e. pybind11 supports binding classes by generating a python class underwater.
No worries, everyone starts as a beginner.
Usually the pattern is that there is a "create_my_type" extern C function that returns a void pointer to python. Then other functions accept that as a parameter "void some_operation(void* my_opaque_type_ptr, int arg1, float arg2);"
Not sure I understand the problem. Passing around opaque void pointers, while frowned upon, is definitely possible with python <-> c interop. You just gotta sprinkle your c++ with extern "C" every point where you interop
For those, like me, who recently joined blue sky, there's apparently a site to search for lists! Go check it out
Well, stuff like reflection, constexpr/consteval, concepts being more powerful.
Either rust or the Safe c++ proposal, which implements the borrow checker for c++.