Careful. We don't want to learn from this.
-- Bill Watterson
This post is going to be a little bit different. I'm going to try at some humor, with just a lace of truth to it to be sad. But isn't the best humor just seeing sad things happen to other people (skadeglädje)?
Template template little class
Someone who thinks that he has understood how templates works in C++ should probably look again. For the handful of people on the planet who actually understand templates, I'll apologize when I encounter them. For the rest, no really. They're hard. Look again closely.
More than one thread? Clearly you must be joking.
Someone who are not scared of multithreaded programming has not been bitten enough. Start your threads and sprinkle some TLS in there, mix it around with some lock less programming and just a dash of semaphores. There. See that crash? Think GPGPU + CPU + SPU = complete mess.
I'm done, put a fork in me
Someone who utters "I think I know all there is to learn about subject X" will soon realize that X is really Y and everything he thought he knew is not really true. Funny enough knowledge only seems to reveal the vastness of subjects to learn.
There is a bug in my compiler!
It's not really a compiler bug. It's simply a bug in your code. If you gather up a number of programmers and then try to drink equal amount of beers that they've found actual bona fida compiler bugs chances are that you will not get drunk. Not even if it's real beer (I mean, if you drink Budwiser then you're out of luck even if you get the compiler team together). The number of times that people cry compiler bug! only to find out that the Microsoft compiler has by default a host of standards breaking extensions that they compare with has been many... too many. If you really want to know if your code is at least not breaking the standard and you only have Visual Studio, either turn on the /Za option or paste a code snippet into the Comeau compiler here.
Really, it must be sad to be a compiler writer, constantly accused of writing buggy software ...
Could I see your license?
There should be a driver's test for C++. If someone insists on programming in this insane language, then they should have levels with language features protected with different classes in the licence. Oh, you're a class F C++ driver? I'm sorry, then you have to take this multiple inheritance out. You're not allowed to use it. If you want to use it, please take the test F13:
- F13.1 Name and explain what the different casts in C++ can do/not do. (See ¶5.2.3, ¶5.2.7, ¶5.2.9, ¶5.2.10 and ¶5.4)
- F13.2 Under what circumstances can you dereference the lvalue of type A through a pointer of type B? (See ¶3.10.15)
Well, I hope you all observe this from afar. Cheers!