r/C_Programming • u/Ok_Reserve996 • Oct 18 '26
C limitations
Hi all,
I am currently learning c++. Its okay. Not sexy but also not as bad as some say.
The reason I am learning c++ is that I have read that C has limitations as soon as a project gets more complicated. For example, if you make a scientific calculator with many features like graphs etc.
Trading engines/tools are also not recommended to programm in C.
Since I have not learned C and have only read from some old forum posts etc, I cannot confirm/deny these facts.
I am aware that "everything" is possible and that C++ comes with QoL improvements especially with Classes. But I assume that doesn't mean that someone has to use C only for kernel work. Embedded is also possible with C++ right?
I would appreciate your thoughts and opinions.
The goal of this post is to understand how and if C could fit me more with my goals and what real advantages or disadvantages C has.
View all comments
Show parent comment
1
u/flatfinger Oct 19 '26
Especially when adapting code written for one platform to make it usable on another, it would be helpful to say that if L is an lvalue of type
struct widget, an expression likeL->woozle+=3;would attempt to invoke a static inline function whose name was based on widget, woozle, and the "add-to" operator, if such a function exists, and otherwise attempt to invoke functions based upon widget, woozle, and the concepts of "read value" and "write value".Unlike C++, a C implementation wouldn't "own" any of the bytes within a structure. If a programmer wants to implement virtual methods, the programmer would need to write a static inline function for the "virtual" member that would chain to the actual function via whatever means the programmer thinks best, using storage within the structure for that purpose exactly as specified in the source code.