summaryrefslogtreecommitdiff
path: root/gcc/cpphash.h
diff options
context:
space:
mode:
authorzack <zack@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-21 18:06:30 +0000
committerzack <zack@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-21 18:06:30 +0000
commit7825551f80daf55c4385294838137954942ae35a (patch)
tree4fb088465e0f2697e44b72ef804c30281053c4db /gcc/cpphash.h
parent28cda66b17a92205021042134cb99ea86230d099 (diff)
downloadgcc-7825551f80daf55c4385294838137954942ae35a.tar.gz
* cpphash.h (struct lexer_state): Add directive_wants_padding.
* cpplib.c (_cpp_handle_directive): Set directive_wants_padding for directives of type INCL. (glue_header_name, parse_include): Use get_token_no_padding. * cppmacro.c (replace_args): If directive_wants_padding, provide padding tokens. * testsuite/gcc.dg/cpp/include3.c: New test. * testsuite/gcc.dg/cpp/inc/foo.h: New file. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@63231 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cpphash.h')
-rw-r--r--gcc/cpphash.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/cpphash.h b/gcc/cpphash.h
index 07880bd2761..9aff511678c 100644
--- a/gcc/cpphash.h
+++ b/gcc/cpphash.h
@@ -214,6 +214,11 @@ struct lexer_state
/* Nonzero if first token on line is CPP_HASH. */
unsigned char in_directive;
+ /* Nonzero if in a directive that will handle padding tokens itself.
+ #include needs this to avoid problems with computed include and
+ spacing between tokens. */
+ unsigned char directive_wants_padding;
+
/* True if we are skipping a failed conditional group. */
unsigned char skipping;