Looks like we’ve got a Java programmer here taking C++ for a spin.
The stone-age called, they want their languages that need header files back!
(I use Rust btw.)
C++ doesn’t anymore, with modules
Why does your header file contain code?
It’s not the case with this meme, but in C++ template definitions have to be defined in the headers if they’re not full template specializations
Oh for fuck sake. I thought the full on retardation hadn’t spread to c.
Why are you putting the implementation in the .h file? You’re supposed to declare in the header and implement in the .cpp files. The meme is reversed
If C++/C were real languages for real programming they’d enforce this in the compiler.
No sane language designer would say “it is imperative that you do not implement your class in its header file” then write a compiler designer to say “oh you implemented your code in the header file? lol lmao that rocks”
They have played you all for fools.
deleted by creator
I actually like how much freedom C++ gives you. As long as it is fed valid code, it does not give a fuck about how you choose to structure your project
That freedom becomes misery on the instant you have to start maintain the code from some other free spirit, whose style is totally different from yours.
Or the free spirit was actually you yourself but from three months ago