[PATCH] Preprocessor: Move IncrementalProcessing to PreprocessorOptions

Axel Naumann Axel.Naumann at cern.ch
Tue Feb 17 02:45:03 PST 2015


Hi Sterling,

> The enclosed patch moves the IncrementalProcessing from a Preprocessor
> field--which is only accessible once the preprocessor is actually
> built--into the PreprocessorOptions

Wow, that's so much nicer!

> The test itself uses two terms, calling it both
> "IncrementalParsing" and "IncrementalProcessing". Not sure if that is
> intentional or not.

Both parser and preprocessor behave slightly differently in incremental
mode, I suppose that's where it comes from. But as you found out both
are steered from the same flag.

Thanks for pinging me!

Cheers, Axel.

On 17/02/15 02:02, Sterling Augustine wrote:
> Hello,
> 
> I'm working on a change that will enable a client to build an AST from
> an input file, and then, based on the contents of that AST, add
> additional tokens to be parsed. Richard Smith recommended adding a
> feature to the parser to do this, but it turns out that there is
> something quite close already: the IncrementalProcessing option, added
> in r152914.
> 
> The enclosed patch moves the IncrementalProcessing from a Preprocessor
> field--which is only accessible once the preprocessor is actually
> built--into the PreprocessorOptions which is available to other
> interfaces which don't expose the preprocessor itself, such as the
> compiler invocation.
> 
> There is only minimal testing of this feature inside
> FrontendActionTest.cpp, but I have updated that as well. I will add
> tests to exercise it more thoroughly once I know that this direction
> is acceptable. The test itself uses two terms, calling it both
> "IncrementalParsing" and "IncrementalProcessing". Not sure if that is
> intentional or not.
> 
> Sterling
> 
> [with cc's to original contributor of the IncrmentalProcessing Axel Naumann]
> 




More information about the cfe-commits mailing list