Commit fb4527c3 by Neil Booth Committed by Neil Booth

cpplex.c (_cpp_lex_line): Maintain PREV_WHITESPACE flag when removing escaped newlines.

        * cpplex.c (_cpp_lex_line): Maintain PREV_WHITESPACE flag
        when removing escaped newlines.  Reverse sense of test for
        escaped newline.

From-SVN: r33816
parent 62c3ad8b
Wed 10 May 09:08:30 2000 Neil Booth <NeilB@earthling.net>
* cpplex.c (_cpp_lex_line): Maintain PREV_WHITESPACE flag
when removing escaped newlines. Reverse sense of test for
escaped newline.
2000-05-09 Richard Henderson <rth@cygnus.com>
* flow.c (find_basic_blocks_1): Do not delete the first
......
......@@ -3010,17 +3010,8 @@ _cpp_lex_line (pfile, list)
case '\n':
case '\r':
handle_newline (cur, buffer->rlimit, c);
if (PREV_TOKEN_TYPE != CPP_BACKSLASH || !IMMED_TOKEN ())
if (PREV_TOKEN_TYPE == CPP_BACKSLASH && IMMED_TOKEN ())
{
if (PREV_TOKEN_TYPE == CPP_BACKSLASH)
{
buffer->cur = cur;
cpp_warning (pfile,
"backslash and newline separated by space");
}
PUSH_TOKEN (CPP_VSPACE);
goto out;
}
/* Remove the escaped newline. Then continue to process
any interrupted name or number. */
cur_token--;
......@@ -3033,7 +3024,17 @@ _cpp_lex_line (pfile, list)
goto continue_number;
cur_token++;
}
/* Remember whitespace setting. */
flags = cur_token->flags;
break;
}
if (PREV_TOKEN_TYPE == CPP_BACKSLASH)
{
buffer->cur = cur;
cpp_warning (pfile, "backslash and newline separated by space");
}
PUSH_TOKEN (CPP_VSPACE);
goto out;
case '-':
if (IMMED_TOKEN () && PREV_TOKEN_TYPE == CPP_MINUS)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment