[cfe-commits] r161650 - in /cfe/trunk: include/clang/Frontend/VerifyDiagnosticConsumer.h lib/ARCMigrate/ARCMT.cpp lib/Frontend/VerifyDiagnosticConsumer.cpp test/ARCMT/verify.m test/ASTMerge/function.c test/Frontend/verify.c test/Frontend/verify2.c test/Frontend/veri

Jordan Rose jordan_rose at apple.com
Wed Aug 15 19:05:54 PDT 2012


On Aug 15, 2012, at 11:19 , Andy Gibbs <andyg1001 at hotmail.co.uk> wrote:

> On Wednesday, August 15, 2012 3:59 AM, Jordan Rose wrote:
>> Stepping back, maybe that's a reason to go back to having two sets.
> 
> Attached is a patch back in the realm of two sets.  I've also gone right
> back to using FileID rather than a combination of FileID and FileEntry in
> what feels like a completed circle!  However, by ensuring that the instance
> of SourceManager doesn't change (which I believe is a valid assumption) and
> by keeping a pointer to it, it means the relevant FileEntry instance can
> always be retrieved from the FileID.  It also has released the checking
> routines from the requirement of the Preprocessor object a little further
> and I believe I can do more to this end later as well, which will be all to
> the good since the Preprocessor is really an unnecessary requirement at
> this stage, and could potentially open up -verify to more uses where no
> Preprocessor is used.
> 
> Hopefully its a lot easier to follow the logic too!
> 
> Is this a step in a better direction?

This looks pretty good to me! I initially thought we could pull all the SourceManager stuff under NDEBUG, but it does make sense to have it used for the actual emitting of errors at the end, rather than pulling it from the preprocessor.

I'll look at this again tomorrow morning (time zone PDT) and commit it then if it all looks good.

Jordan



More information about the cfe-commits mailing list