For me code serves 2 purposes:

1) Obvious one: Specify the steps to solve a problem
2) Communicate with other engineers

In the original implementation there is so much noise. That is why I extracted the semantics of all this #ifndef and put them on a method. So, my primary motivation to move this out is to have the discover method more readable, more expressing the algorithm, rather than being all cluttered with noise.

Obviously you don't like this, why? Can this cause a compilation error if none of the #ifnodef is met -> empty method?