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
de5f1a5a
Commit
de5f1a5a
authored
Jan 23, 1993
by
Richard Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(change_newlines): Renamed from delete_newlines.
Insert a space in place of a newline. Caller changed. From-SVN: r3314
parent
028aaf1a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
gcc/cccp.c
+10
-8
No files found.
gcc/cccp.c
View file @
de5f1a5a
...
...
@@ -263,7 +263,7 @@ static int compare_defs ();
static
int
compare_token_lists
();
static
int
eval_if_expression
();
static
int
discard_comments
();
static
int
delet
e_newlines
();
static
int
chang
e_newlines
();
static
int
line_for_error
();
static
int
hashf
();
static
int
file_size_and_mode
();
...
...
@@ -7260,11 +7260,11 @@ macroexpand (hp, op)
lines which don't correspond to any input line, which confuses
gdb and gcov. */
if
(
arg
->
use_count
>
1
&&
arg
->
newlines
>
0
)
{
/* Don't bother doing
delet
e_newlines for subsequent
/* Don't bother doing
chang
e_newlines for subsequent
uses of arg. */
arg
->
use_count
=
1
;
arg
->
expand_length
=
delet
e_newlines
(
arg
->
expanded
,
arg
->
expand_length
);
=
chang
e_newlines
(
arg
->
expanded
,
arg
->
expand_length
);
}
}
...
...
@@ -7659,12 +7659,12 @@ discard_comments (start, length, newlines)
return
obp
-
start
;
}
/*
Delete newlines in the string of length LENGTH at START, except inside
of string constants. The string is copied into itself with its beginning
staying fixed. */
/*
Turn newlines to spaces in the string of length LENGTH at START,
except inside of string constants.
The string is copied into itself with its beginning
staying fixed. */
static
int
delet
e_newlines
(
start
,
length
)
chang
e_newlines
(
start
,
length
)
U_CHAR
*
start
;
int
length
;
{
...
...
@@ -7682,11 +7682,13 @@ delete_newlines (start, length)
switch
(
c
)
{
case
'\n'
:
/* If this is a NEWLINE NEWLINE, then this is a real newline in the
output. Skip past the newline and its duplicate. */
string. Skip past the newline and its duplicate.
Put a space in the output. */
if
(
*
ibp
==
'\n'
)
{
ibp
++
;
obp
--
;
*
obp
++
=
' '
;
}
break
;
...
...
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