Template:Ifwpc/doc

This template compares branching methods with and without.

It shows, for all 27 possibilities of three parameters being non-empty, empty or undefined, the result of Template:Ifwp, #if with empty strings as default, and the concatenation of Template:Ifdef and Template:Ifndef.

Code:

All differences between the three methods occur with undefined and  non-empty, in which case the codes reduce to:

Differences between undefined and empty (which may or may not be desirable) occur in two methods with non-empty, and  and  each empty or undefined, in which case the codes reduce to:

Substitution
Substitution works for all three methods.