Message from @meratrix
Discord ID: 464511517841424394
why RAII?
Most of the time you don't even have to remember about moves.
Like, `T&&`.
Just take by value.
I guess, but I kinda feel like that's part of what makes it a ~C language
RAII, let all resource cleanup happen automatically. Suddenly you notice 90% of your destructors are empty, the other 10% is trivial.
And you barely need `try/catch`.
Point taken, but I've never particularly disliked writing destructors.
then again I'm not maintaining huge C++ codebases at the moment so I have that luxury
i agree with anything that lets me avoid try/catch
A month or so ago I was doing some serial/FTDI coding. Rewrote a utility originally in C. Half of the original code was error handling and cleanup. The C++ version had just 5 lines in `main()` to report the error message, no explicit error handling or cleanup anywhere else.
nice
Any time an exception would happen, the class would properly reset the device to a known state. So I could just read/write without worry.
Ever since I started titling myself "Computer Programmer" I keep getting offered odd non-programming basic tech jobs by random people.
haha, because people don't know what "computer programmer" means
I helped fix my friends computer, and she goes "so this is what you do all day for work?" 😦
I told her I have IT people to fix my computer for me at work...but a lot of people just don't understand the differentiation between different tech specializations
I'm half tempted to take the jobs. If I can get a programmer cut for IT work
So far my trainer asked if I could set up his new laptop. Ok thats insanely easy, it basically does it all automatically. At most I might do a windows reinstall, even then its a button press. Other job was by a local coffee shop owner who wanted someone that could "hack" information. He wanted to make a dectective agency and wanted a tech guy. Kinda out there that guy. Even then, it would just be social engineering to get info which can be done by anyone that knows how to work social media
@meratrix
>be studying CS
>Family: CAN YOU FIX MY COMUPUTER???????????????
My family is picking up on the backlash to that sentiment, sloooooooooooooowly
CS doesn't involve knowledge of computer parts other than how they function in particular. Just tell them to find someone versed in IT or whatnot. x3
IT is a waste of time for programmers.
In regards to earlier: GC tends to be pretty resource heavy.
But GC is pretty essential.
Also, yeah, having a hard-on for programming in C++ is a bit detrimental, while it's absolutely essential to have fundamental knowledge of lower-level programs and how any language you're currently using that's higher level will be parsed and compiled into at a base level (for optimization purposes) holding onto only working in C++ just kills your ability to program something in a short/efficient period of time.
C++ is very high level dude.
The only edge other languages have is the easy-to-install 3rd party modules.
Who knows, maybe C++23 will have modules.
MS has been pushing for their own horrible package manager.
And I'll take RAII over GC any day.
GC is a tool for only one kind of resource, memory. RAII is more general. You can start to think about various things as resources that can be managed.
Well, I don't know about you, but I don't know many people that actually work directly with assembly. @DanielKO
I only work with it when I've reverse-engineering keygen mes.
``` L = L1;
L <<= 16;
L |= L2;
L >>>= 0;
R = R1;
R <<= 16;
R |= R2;
R >>>= 0;``` I remember this one.
And then my code comments like this.
I only ever do littl snippets of inline stuff for specific functionality on embedded stuff now
but even that is super super rare
*ASM↑