C++ - Reddit – Telegram
C++ - Reddit
226 subscribers
48 photos
8 videos
24.3K links
Stay up-to-date with everything C++!
Content directly fetched from the subreddit just for you.

Join our group for discussions : @programminginc

Powered by : @r_channels
Download Telegram
Curious to know about developers that steered away from OOP. What made you move away from it? Why? Where has this led you?

TLDR: i'm just yapping about where I come from but am very interested about what I asked you about in the noscript!

So I been all in into developing games for 2 years now coming from a 3D artist background and became recently very serious about programming after running into countless bottlenecks such as runtime lag spikes, slow code, unscalable code (coupling), code design too content heavy (as in art assets and code branching logic) and so on.

But while learning about programming and making projects, I always found that something about OOP just always felt off to me. But I never was able to clearly state why.

Now I know the hardware dislikes cache misses but I mean it still runs...

Thing is there's something else. People say they use OOP to make "big projects more scalable" but I kind of doubt it... It looks to me like societal/industry technical debt. Because I don't agree that it makes big projects much more scalable. To me, it feels like it's just kind of delaying inevitable spaghetti code. When your building abstraction on top of abstraction, it feels just so... subjective and hard to keep track of. So brittle. Once too big, you can't just load into your brain all the objects and classes to keep track of things to keep developing there comes a point where you forget about things and end up rewriting things anyway. And worst case about that is if you rewrite something that was already written layers beneath where now you're just stacking time delays and electricity/hardware waste at this point. Not only to mention how changing a parent or shared code can obliterate 100 other things. And the accumulation of useless junk from inheritance that you don't need but that'll take ram space and even sometimes executions. Not only to mention how it forces (heavily influences) you into making homogeneous inheritance with childrens only changing at a superficial level. If you look at OOP heavy games for example, they are very static. They are barely alive barely anything is being simulated they just fake it with a ton of content from thousands of artists...

Like I get where it's power lies. Reuse what has been built. Makes sense. But with how economy and private businesses work in our world, technical debt has been shipped and will keep being shipped and so sure I get it don't reinvent the wheel but at the same time we're all driving a car with square wheels wondering why our gas bills are ramping up...

So with that being said, I been looking for a way out of this madness.

Ignorant me thought the solution was about learning all about multithread and gpu compute trying to brute force shit code into parallelism lol.

But I just now discovered the field of data structure and algorithms and for the first time in who knows how long I felt hope. The only downside is now you need to learn how to think like a machine. And ditch the subjective abstract concepts of OOP to find yourself having to deal with the abstraction of math and algorithms lol

But yeah so I was hoping I could hear about others that went through something similar. Or maybe to have my ignorance put in check I may be wrong about all of it lol. But I was curious to know if any of you went through the same thing and if that has led you anywhere. Would love to hear about your experience with the whole object oriented programming vs data oriented programming clash. And what better place to come ask this other than the language where the two worlds collide! :D

https://redd.it/1phxghq
@r_cpp
IDE for C++

Hi,
I'm currently using Code::Blocks and VS Code to code C++ and everything else.
I think about switching to a real IDE, but I can't choose between Visual Studio Community and Clion. Which of the two IDEs to choose and is better?

https://redd.it/1pi53fv
@r_cpp
Dependency Injection In c++

Hey, curious about the preferred dependency injection patterns in modern c++. preferably c++20 and above.

https://redd.it/1pi5fro
@r_cpp
What to expect in Kodiak AI Interview

I have an upcoming interview with Kodiak AI for a C++ Motion Planning New Grad role on their Autonomy team, and I’m trying to get a realistic idea of what the technical rounds look like. For folks who have interviewed there (or at similar AV/autonomy companies):

How much of the interview is “standard” C++ LeetCode-style questions vs questions focused on autonomy algorithms (motion planning, behavior planning, trajectory generation, computational geometry, controls?

My background is in robotics and motion planning with intermediate knowledge C++ as I’ve mainly used it in ROS codes, so I’m wondering how to split prep time between LeetCode, core C++ fundamentals, and autonomy-specific algorithm/design prep. Any insight or recent experiences would be hugely appreciated.

https://redd.it/1pibqct
@r_cpp
[Show and Tell] u8ility: A C++20/23 header-only, zero-allocation UTF-8 view library

Hi r/cpp,

This is my first post in this subreddit, so I'll try my best to follow the guidelines and provide some value!

Back in 2021, I started working on a simple UTF-8 library to avoid the dependency overhead required for basic codepoint interaction in my project. \
I recently dusted it off and decided to completely rewrite it to create the thinnest possible wrapper around std::string_view, to meet modern C++ standards that provide correct iteration of code points, focusing solely on performance and ergonomics.

### Key Design Principles:
- **Header-only**: Ease of use by providing complete details on what's under the hood

- **Zero-Allocation**: The core character type (`u8::mchar`) is a small, stack-based value type (max 5 bytes). It avoids heap allocation entirely during iteration

- **Cache-Friendly**: By avoiding pointers and virtual calls, it ensures high cache locality when iterating

- **Constexpr**: Allows encoding, decoding, and basic character validation at compile-time

- **Ergonomic**: Provides an u8::u8_view that works flawlessly with range-based for loops

I believe this offers an efficient alternative to full-featured libraries *when you just need quick, safe access to UTF-8 characters within existing `std::string` data*.

I'd love your roast/feedback on the current implementation. I'm especially interested in whether the char8_t vs char interoperability feels correct and how I could further improve validation logic without breaking the zero-allocation rule.

Here is [the Github link](https://github.com/lmela0/u8ility) 🙏

`https://github.com/lmela0/u8ility`

https://redd.it/1pilv04
@r_cpp
Ask Me Anything session with CLion team

Hi r/cpp,

The **CLion** team is excited to host an **AMA (Ask Me Anything)** session tomorrow **Thursday, December 11, 2025**.

Feel free to join us over at r/Jetbrains or drop your questions right here – we’ve got you covered!

[https://www.reddit.com/r/Jetbrains/comments/1pia836/ask\_me\_anything\_with\_clion\_team\_december\_11\_1\_pm/](https://www.reddit.com/r/Jetbrains/comments/1pia836/ask_me_anything_with_clion_team_december_11_1_pm/?utm_source=share&utm_medium=web3x&utm_name=web3xcss&utm_term=1&utm_content=share_button)

[CLion](https://www.jetbrains.com/clion/) is a cross-platform IDE for C and C++ designed for smooth workflows and productive development. It is ready to use out of the box with all essential integrations in one place and supports major toolchains, popular build systems, unit testing frameworks, and advanced debugging, as well as embedded development.

This Q&A session will cover the latest updates and changes in CLion. Feel free to ask any questions about our latest 2025.3 release, CLion language engine updates and new language features, debugger enhancements, project models and build tools support, and anything else you're curious about!

**We’ll be answering your questions from 1–5 pm CET on December 11.**

**Your questions will be answered by:**

* Artemy Pestretsov (Head of the C/C++ Ecosystem) – u/artemypestretsov
* Andrey Gushchin (CLion Product Manager) – u/andrey-gushchin
* Evgenii Novozhilov (Engineering Lead) – u/ujohnny
* Aleksander Karaev (C/C++ Language Support Lead) – u/FortuneSpiritual6290
* Ilia Motornyi (CLion Developer, Embedded) – u/_elmot

There will be other members of the CLion team helping us behind the scenes.

We’re looking forward to seeing you!

Your CLion team, 

JetBrains



https://redd.it/1piyfzp
@r_cpp
Visual Studio option /RTCc - what is its purpose?

Why does it exist?
Documentation says that it “Reports when a value is assigned to a smaller data type and results in a data loss.”
Except it is not what it actually does.
This runtime check reports a failure if discarded by a cast top bits are not the same (all 0 or all 1).
It is not a useful range check for either signed or unsigned types, almost as if someone did it to offend both equally...
I just can't understand why such an utterly useless option has been kept in a compiler for decades.
Am I missing something here?

https://redd.it/1pj0hyr
@r_cpp
What's better for robotics Cmake or Autotools ?

The noscript pretty much explains it. I recently watched CodingJesus video on the "C++ Wretch Build" (Like from Elden Ring) aka the build that will give you the least assitance to start out with but open up a lot of possibilities. I am very new to C++ and Robotics (just started with Arduino, Breadboard etc) In his video he detailed autotools was the best for getting "cracked" as a C++ developer. I want to be a robotics electrical engineer and I am aware that maybe some of his suggestions for this wretch build were maybe specific to developers.I asked chatgpt and google and the AI given answer was CMake was overwhelmingly better but I saw a lot of debate on reddit.


Context: This is his suggested "build"🌑

Wretch Starter Kit

Build System: Autotools
Debugger: GDB
IDE: Vim + tmux
Compiler: GCC
Linter: clang-tidy
Formatter: clang-format
Profiler: perf
git






https://redd.it/1pj4cy2
@r_cpp
How do compilers execute constexpr/consteval functions when you are cross-compiling?

I assume that you can not just compile and run for the host platform, since e.g. long can have a different size on the target platform.

Can the compiler just use the type sizes of the target platform, and then execute natively?

Can this problem be solved in different ways?

https://redd.it/1pj8qxk
@r_cpp