summaryrefslogtreecommitdiff
path: root/gcc/cpplex.c
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.demon.co.uk>2002-05-11 21:02:34 +0000
committerNeil Booth <neil@gcc.gnu.org>2002-05-11 21:02:34 +0000
commit387f9e323b1b61d355b3ee6a0d843e26d21bf2de (patch)
treea8d85fe940ad3bc6aecad76f5620ba2746144cb2 /gcc/cpplex.c
parente1a0f69c8f59e39584e50f912a38ba84dadcf431 (diff)
downloadgcc-387f9e323b1b61d355b3ee6a0d843e26d21bf2de.tar.gz
cpplex.c (_cpp_lex_direct): When in a directive at EOF fake a newline.
* cpplex.c (_cpp_lex_direct): When in a directive at EOF fake a newline. From-SVN: r53386
Diffstat (limited to 'gcc/cpplex.c')
-rw-r--r--gcc/cpplex.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/cpplex.c b/gcc/cpplex.c
index bba6f074730..f2d07963f79 100644
--- a/gcc/cpplex.c
+++ b/gcc/cpplex.c
@@ -930,7 +930,7 @@ _cpp_lex_direct (pfile)
/* EOF. */
buffer->cur--;
buffer->saved_flags = BOL;
- if (!pfile->state.parsing_args && !pfile->state.in_directive)
+ if (!pfile->state.parsing_args)
{
if (buffer->cur != buffer->line_base)
{
@@ -942,7 +942,7 @@ _cpp_lex_direct (pfile)
}
/* Don't pop the last buffer. */
- if (buffer->prev)
+ if (!pfile->state.in_directive && buffer->prev)
{
unsigned char stop = buffer->return_at_eof;