This play on words depends both upon the reader's acquaintance with the meaning of the phrase Virtual Function, and here upon the currency of that phrase in the jargon of a specialized audience. In English, as in most languages, humor (however mild it may be, as in this example) sometimes depends for its success upon eliciting surprise in, or confounding the expectation of, the reader: here an expected modifer in a well known phrase is omitted from the title sentence, and this comes as a (mild) surprise. If there were a term for this particular form of deletion, it might be predictive ellipsis,† or, taking a page from medical usage, phantom ellipsis.†
The article here describes functions which appear to be Virtual Functions, but which, upon analysis, are not. The modifier in the common phrase, Virtual, is deleted from the sentence as written, but the reader, expecting it to follow the negation, perceives the question as When is a Virtual Function Not (Virtual)?
The same device might be employed in precisely the same way in the title of an article about a substandard campground:
When is a Happy Camper Not?
Another example might be the title of an article which describes a particularly boring National Football League championship contest in the U.S:
Why Was The Super Bowl Not?
Note that this device will not be effective when the phrase employed has no "identity" of its own as a well known phrase, as in:
When is a Green Taxi Not?
† In the event that this form of deletion has no name, I will accept credit for either coinage. If, as I suspect, there is a term already in use, I do not doubt that it will be provided in commentary.