"Daniel Murphy" <yebbl...@nospamgmail.com> wrote in message news:km7lir$48g$1...@digitalmars.com... > "Walter Bright" <newshou...@digitalmars.com> wrote in message > news:km7fml$2rka$1...@digitalmars.com... >> When devising solutions, I want to prefer solutions that do not rely on >> #ifdef/#endif. I've tried to scrub those out of the dmd front end source >> code. > > I completely agree. But - refactoring the glue layer interface to use a > proper visitor interface (what I suspect is the best solution) is a rather > large change and will be much easier _after_ the conversion. > > While ifdefs are a pain in general, the big problem is this pattern. > if (a && b && > #if SOMETHING > c && d && > #else > e && f && > #endif > g && h) { > ...
It turns out these are actually not that big a problem in the frontend - around 30 cases, all DMDV2 or 0/1. The backend is another story...