Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
c2e25d51
Commit
c2e25d51
authored
Apr 26, 2000
by
Neil Booth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* cpplex.c: fix typos in comment
From-SVN: r33444
parent
d6d5f795
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
9 deletions
+10
-9
gcc/cpplex.c
+10
-9
No files found.
gcc/cpplex.c
View file @
c2e25d51
...
@@ -2106,21 +2106,22 @@ _cpp_init_input_buffer (pfile)
...
@@ -2106,21 +2106,22 @@ _cpp_init_input_buffer (pfile)
trigraphs and escaped newlines in the input stream.
trigraphs and escaped newlines in the input stream.
The trigraphs are three consecutive characters beginning with two
The trigraphs are three consecutive characters beginning with two
question marks. A question mark is not a valid as part of a number
question marks. A question mark is not valid as part of a number or
or identifier, so parsing of a number or identifier terminates
identifier, so parsing of a number or identifier terminates normally
normally upon reaching it, returning to the mainloop which handles
upon reaching it, returning to the mainloop which handles the
the trigraph just like it would in any other position. Similarly for
trigraph just like it would in any other position. Similarly for the
the backslash of a backslash-newline combination. So we just need
backslash of a backslash-newline combination. So we just need the
the escaped-newline dropper in the mainloop to check if the token on
escaped-newline dropper in the mainloop to check if the token on the
the top of the stack is a number or identifier, and to continue the
top of the stack after dropping the escaped newline is a number or
processing of the token as if nothing had happened.
identifier, and if so to continue the processing it as if nothing had
happened.
For strings, we replace trigraphs whenever we reach a quote or
For strings, we replace trigraphs whenever we reach a quote or
newline, because there might be a backslash trigraph escaping them.
newline, because there might be a backslash trigraph escaping them.
We need to be careful that we start trigraph replacing from where we
We need to be careful that we start trigraph replacing from where we
left off previously, because it is possible for a first scan to leave
left off previously, because it is possible for a first scan to leave
"fake" trigraphs that a second scan would pick up as real (e.g. the
"fake" trigraphs that a second scan would pick up as real (e.g. the
sequence "????
\
\n=" would find a fake ??= trigraph after removing the
sequence "????
/
\n=" would find a fake ??= trigraph after removing the
escaped newline.)
escaped newline.)
For line comments, on reaching a newline we scan the previous
For line comments, on reaching a newline we scan the previous
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment