diff options
author | Dave Brolley <brolley@cygnus.com> | 1998-06-10 10:18:45 +0000 |
---|---|---|
committer | Dave Brolley <brolley@gcc.gnu.org> | 1998-06-10 06:18:45 -0400 |
commit | ab9e0ff9c7fc514f6e5cfcadef49b233a706917b (patch) | |
tree | 83471fce0622c0edc93ed0faa3f673c2747f8c70 /gcc/f/parse.c | |
parent | 297441fd872faf63cfb9ed802975fc8ebcb69a91 (diff) | |
download | gcc-ab9e0ff9c7fc514f6e5cfcadef49b233a706917b.zip gcc-ab9e0ff9c7fc514f6e5cfcadef49b233a706917b.tar.gz gcc-ab9e0ff9c7fc514f6e5cfcadef49b233a706917b.tar.bz2 |
New interface for lang_decode_option.
Wed Jun 10 13:17:32 1998 Dave Brolley <brolley@cygnus.com>
* top.h (ffe_decode_option): New argc/argv interface.
* top.c (ffe_decode_option): New argc/argv interface.
* parse.c (yyparse): New argc/argv interface for ffe_decode_option.
* com.c (lang_decode_option): New argc/argv interface.
From-SVN: r20409
Diffstat (limited to 'gcc/f/parse.c')
-rw-r--r-- | gcc/f/parse.c | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/gcc/f/parse.c b/gcc/f/parse.c index 1efdc77..a25a9ec 100644 --- a/gcc/f/parse.c +++ b/gcc/f/parse.c @@ -52,11 +52,18 @@ yyparse () #if FFECOM_targetCURRENT == FFECOM_targetFFE ffe_init_0 (); - for (--argc, ++argv; argc > 0; --argc, ++argv) - { - if (!ffe_decode_option (argv[0])) - fprintf (stderr, "Unrecognized option: %s\n", argv[0]); - } + { + int strings_processed; + for (--argc, ++argv; argc > 0; argc -= strings_processed, argv += strings_processed) + { + strings_processed = ffe_decode_option (argc, argv); + if (strings_processed == 0) + { + fprintf (stderr, "Unrecognized option: %s\n", argv[0]); + strings_processed = 1; + } + } + } #elif FFECOM_targetCURRENT == FFECOM_targetGCC if (!ffe_is_pedantic ()) ffe_set_is_pedantic (pedantic); |