Couldn't we have in the first phase a weak preprocessor that only preprocesses external headers in order to determine the program structure and without these macros affecting .cpp files? I mean preprocess <stdio.h> and all it's includes, parse once that file to determine what functions it contains, cache and make that list available to .cpp files without actually having those macros effect the way Assiste++ sees out .cpp files? This implementation would be much easier.