Tomalak Geret'kal

Yes Alex, The Standard Doesn't Mention The Stack, And That's Fine

Alex Darby writes about "the Stack", referring to both the ISO standard and Bjarne's C++ book and complains that they both evade the concept of a stack or a heap as used for laying-out objects in memory.

What's Different About Static Members Defined In-line?

While writing my previous post, a question came to mind regarding the use of static members for bounding arrays that are members of the same type.

Tomalak's Tuesday Tip #13: When Is A Scoped Lock Not A Scoped Lock?

A piece of supposedly well-written multi-threaded code was giving me a headache the other day. I briefly explore a common(?) pitfall in the use of RAII-driven locking mechanisms.

Ruby Does Equality Right, And C++ Does Not

I was posed a question recently as to why the C++ expression true == true == true compiled successfully. The person asking was sure that equality comparison held no associativity and that the expression was thus too ambiguous to be well-formed.

Debunking Leitner

I was linked earlier on to a presentation entitled "The Dark Side Of C++", written in August 2007 by C expert Felix von Leitner. He attempts to explain C++'s pitfalls and demonstrate why a programmer should choose another language. Though the intention is sound and some good points are made, unfortunately it also contains untruths. Therefore, I shall go through parts of the presentation, debunking its lies.

Iterator Invalidation Rules (C++0x)

A version of my previous post (a tidy, all-in-one table of all the C++03 container iterator invalidation rules) updated for C++0x.

Iterator Invalidation Rules (C++03)

I've not found a tidy, all-in-one table of all the C++03 container iterator invalidation rules. So, with references, here they are!

Tomalak's Tuesday Tip #11: Sleep Your Way To Success

Tempted to count the passage of CPU time with the clock() POSIX call? Be careful.

Tomalak's Tuesday Tip #10: How to Iterate-Erase Over Maps

Keeping it low-key this week, let's re-iterate (lol) the conventional map-erase idiom in C++.

Tomalak's Tuesday Tip #9: Befriending Your Parser

In an unprecedented feat of miraculousness, Freenode's ##C++ discussion channel saw — in the space of no more than twenty minutes — the same question asked twice of one of C++'s more subtle features. Just how do you declare a friend from the global namespace? I find out.

Next Page »