Every time I try to code in C/C++ I give up 10 minutes later and say this shit would be easier in a more modern language with GC.
In their defense, modern C++ is quite different then the older stuff. It is just that there is so much built up history of old C++ code that it's hard to get away from.
Edit: C++ gives you the tools to shoot yourself in te foot and developers choose to shoot themselves in the foot constantly with it. (Mostly cus we got tired of reading the docs)
Or y’know there will be low-level programmers who worry about these things and high-level programmers who are worrying about how to efficiently create complex products using the technologies created by the low-level programmers. Which is what we already have, and is how it should be.
Would that be a bad thing? I mean, isn't that the point of high and low-level languages? A JS programmer doesn't need to know what the stack and heap are for a reason, I guess?
How can you understand performance if you don't know how indirection works? How can you consider security implications if you don't know what a stack is, let alone a stack overflow?
It's great that we're abstracting away the work involved with constantly considering how to micro-manage memory, but we abstract away the understanding at our own peril.
Part of the whole idea of high level languages is that you shouldn't have to worry about a stack overflow in one. Leave memory management to the people doing systems and compiler programming, build userland stuff out of components that are built by someone smarter than you.
Academics/researchers who use programming to do data crunching these days may not even understand what kind of parts are in a computer. Hell, I know a few who don't even know how to use a touchpad or keyboard shortcuts properly.
Even excel programming (because it is in its own way a type of programming) is often done by people who don't know anything about how computers work and may not even understand that excel is just a spreadsheet program.
But, whilst a software developer or engineer may scoff at this, it's definitely good that people can use computers to augment their work, to make their lives easier and it's good that it's accessable for those who may need it.
That doesn't mean that the lower level, the software engineer, or developer, is going to disappear, there will always be a need to write assembly, C, Python, Java, or whatever other languages take root.
And it is good that you don't always have to know what a register is, or how to write an OS, or how ARM is different to x86 just to write a script that calculates the reaction rates in your lab.
This is such a snobby & elitist viewpoint in a world where a marketable, performant and fully functional full-stack application can be written in countless high-level languages, none of which require ever working with binary or worrying about memory management. Sounds like your definition of a "real programmer" is them having knowledge about low-level programming concepts, and not the ability to actually build software.
Knowing the basics like binary and stack is good but not essential most of the time nowadays. A cs alumni who can't code properly will be rejected over a good self taught programmer, unless the job is at a big company that can and will train him/her.
And btw real programmers are only those who program in C or assembly, on Linux (never ever Windows) without GUI (after all it's made for the plebeian average users, not for the power users), only 100% terminal and text, like in the 70s. A real programmer doesn't use a totally incomplete and powerless text editor like VS Code, we only use modern and productive tools like vi, emacs and vim...
Oh- wait, that's not how it works. And I'm glad it isn't.
You don't really need it to write code. But having a fundamental unterstanding of computers does have it's benefits. Programming requires a certain mindset, a certain way of thinking and that way of thinking is dictated by how computers work. Having knowledge on how computers operate makes it far easier to get into this kind of thinking
Ugh, meanwhile I find GC's absolutely infuriating as a C++ programmer. I make heavy use of RAII so I'm frequently relying on destructors being called at known times to ensure correct behavior.
Granted Unreal C++ has a decent middle ground where you have hooks for when things are being cleaned up/marked for cleanup.
I'm honestly pretty surprised by this sentiment. Like I understand why pointers might be hard to understand at first, but most of C doesn't seem too difficult at all relative to other high level programming languages.
Lack of standardization with development tools, compilers and processes (clang, GCC, VS C++, CMAKE, SCons, VS, Vim)
Need to manually write H files - its literally just duplicate code - though historically I understand its purpose.
Non-standard tooling (outside of windows)
So many types of pointers it's confusing AF to new comers (auto_ptr, unique_ptr, shared_ptr and weak_ptr--lets not forget about naked pointers)
Sometimes it feels like a magical incantation to get code to work (more often than any other language I've worked in) as
Lack of native package and dependency management. (ala, NPM, Cargo, PIP etc)
Truly EGREGIOUS operator overloading throughout the language that's become normalized by devs. (cout for example overrides << vs using quotes and function call like most other languages)
A personal gripe, I think due to the history of the language implicit typing (auto) should not have been introduced. Most other languages that use this (C#, the tooling, language conventions and others) it is much easier to understand and infe, in C++ its ripe for abuse like operator overloading.
Yep I know enough about both to know I'm not a C programmer and the first language I started with was C and I spent a lot of time with it. I feel like I could probably get up to speed on it now because a language is a language but I don't know why I would. I've been developing with web tech for 20 years now. I generally don't need that bare iron access but I have respect for the ones that really use that to it's fullest. Otherwise, if they're making form apps with basic UI, why are they using C?
112
u/brockisawesome May 01 '22
I'm an actual js person, and always treat the C++ guys at work like wizards