if (cond) {

    typedef int type;

} else {

    typedef double type;

}

type x;

 

 

This is useful in many ways, as one can check for cond ni one place, rather than use global variables, & check 27 times...