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
0c70c30f
Commit
0c70c30f
authored
Oct 19, 1999
by
Nick Clifton
Committed by
Nick Clifton
Oct 19, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not generate error message about unrecognised command line switches of
other languages. From-SVN: r30085
parent
61e8b354
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
1 deletions
+41
-1
gcc/ChangeLog
+7
-0
gcc/toplev.c
+34
-1
No files found.
gcc/ChangeLog
View file @
0c70c30f
Tue
Oct
19
14
:
01
:
34
1999
Nick
Clifton
<
nickc
@cygnus
.
com
>
*
toplev
.
c
(
main
)
:
Do
not
generate
an
error
message
if
an
unrecognised
command
line
switch
is
recognisable
by
another
language
.
If
extra_warnings
are
enabled
,
then
generate
a
warning
message
instead
.
Tue
Oct
19
11
:
41
:
12
1999
Mumit
Khan
<
khan
@xraylith
.
wisc
.
edu
>
Tue
Oct
19
11
:
41
:
12
1999
Mumit
Khan
<
khan
@xraylith
.
wisc
.
edu
>
*
c
-
pragma
.
h
(
PRAGMA_INSERT_ATTRIBUTES
)
:
Delete
macro
.
*
c
-
pragma
.
h
(
PRAGMA_INSERT_ATTRIBUTES
)
:
Delete
macro
.
...
...
gcc/toplev.c
View file @
0c70c30f
...
@@ -5414,7 +5414,40 @@ main (argc, argv)
...
@@ -5414,7 +5414,40 @@ main (argc, argv)
?
lang_processed
:
indep_processed
);
?
lang_processed
:
indep_processed
);
else
else
{
{
warning
(
"ignoring option `%s'"
,
argv
[
i
]);
const
char
*
option
=
NULL
;
const
char
*
lang
=
NULL
;
unsigned
int
j
;
/* It is possible that the command line switch is not valid for the
current language, but it is valid for another language. In order
to be compatible with previous versions of the compiler (which
did not issue an error message in this case) we check for this
possibilty here. If we do find a match, then if extra_warnings
is set we generate a warning message, otherwise we will just
ignore the option. */
for
(
j
=
0
;
j
<
NUM_ELEM
(
documented_lang_options
);
j
++
)
{
option
=
documented_lang_options
[
j
].
option
;
if
(
option
==
NULL
)
lang
=
documented_lang_options
[
j
].
description
;
else
if
(
!
strncmp
(
argv
[
i
],
option
,
strlen
(
option
)))
break
;
}
if
(
option
)
{
if
(
extra_warnings
)
{
warning
(
"Ignoring command line option '%s'"
,
argv
[
i
]);
if
(
lang
)
warning
(
"\
(It is valid for %s but not the selected langauge)"
,
lang
);
}
}
else
error
(
"Unrecognised option `%s'"
,
argv
[
i
]);
i
++
;
i
++
;
}
}
}
}
...
...
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