Jeff,
here is an updated patch with changelog. I've added checking_asserts
and comments for the state changes you were concerned about.
While the __builtin_expects do make a change to generated code, you are
probably right that they are not significant and I have removed them --
cpplib tends
Nathan Sidwell writes:
> > This doesn't seem to match the code to go into directives mode all that
> > well.? You don't reset pragma_allow_expansion or directive_line.
>
> Hm, yeah. I think neither of those fields have any bearing in
> non-directives mode, and always get set when entering it?
On 11/6/20 3:23 PM, Jeff Law wrote:
04-cpp-lexer.diff
diff --git c/libcpp/include/cpplib.h w/libcpp/include/cpplib.h
index 8e398863cf6..81be6457951 100644
--- c/libcpp/include/cpplib.h
+++ w/libcpp/include/cpplib.h
@@ -888,9 +915,9 @@ struct GTY(()) cpp_hashnode {
unsigned int directive_i
On 11/3/20 2:13 PM, Nathan Sidwell wrote:
> c++ modules creates 2 new kinds of preprocessor lines
> [export] module ...
> [export] import ...
>
> To all intents and purposes these are cppdirectives spelt without a
> leading '#'. module and import are context-sensitive keywords. Thus
> preproces
On 11/3/20 6:08 PM, Joseph Myers wrote:
On Tue, 3 Nov 2020, Nathan Sidwell wrote:
@@ -888,9 +915,9 @@ struct GTY(()) cpp_hashnode {
unsigned int directive_index : 7; /* If is_directive,
then index into directive table.
On Tue, 3 Nov 2020, Nathan Sidwell wrote:
> @@ -888,9 +915,9 @@ struct GTY(()) cpp_hashnode {
>unsigned int directive_index : 7; /* If is_directive,
> then index into directive table.
> Otherwise, a NODE_OPERATO
c++ modules creates 2 new kinds of preprocessor lines
[export] module ...
[export] import ...
To all intents and purposes these are cppdirectives spelt without a
leading '#'. module and import are context-sensitive keywords. Thus
preprocessor tokenizing needs a bit of token peeking. This is