From 7b086b11df0c065c531a6cf2aa505504fe9ec8e2 Mon Sep 17 00:00:00 2001 From: Neil Booth Date: Mon, 16 Jun 2003 05:47:07 +0000 Subject: c-opts.c (c_common_handle_option): s/on/value/. * c-opts.c (c_common_handle_option): s/on/value/. (OPT_fabi_version_, OPT_ftabstop_, OPT_ftemplate_depth_): Use value directly rather than converting the argument. * c.opt: Update docs. Use UInteger where appropriate. * common.opt: Use UInteger where appropriate. * opts.c (integral_argument): New. (handle_argument): Handle integral arguments, and optional joined arguments. (common_handle_option): Update. * opts.h (CL_MISSING_OK, CL_UINTEGER): New. * opts.sh: Handle JoinedOrMissing and UInteger flags. java: * lang.c (java_handle_option): Special-casing of optional joined arguments no longer needed. * lang.opt: Update switches that take optional argument. From-SVN: r67999 --- gcc/java/ChangeLog | 6 ++++++ gcc/java/lang.c | 13 ++----------- gcc/java/lang.opt | 8 ++++---- 3 files changed, 12 insertions(+), 15 deletions(-) (limited to 'gcc/java') diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index e2c5866..634aca6 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,9 @@ +2003-06-16 Neil Booth + + * lang.c (java_handle_option): Special-casing of optional + joined arguments no longer needed. + * lang.opt: Update switches that take optional argument. + 2003-06-15 Neil Booth * lang.opt: Declare Java. diff --git a/gcc/java/lang.c b/gcc/java/lang.c index ff20985..07d5647 100644 --- a/gcc/java/lang.c +++ b/gcc/java/lang.c @@ -274,17 +274,8 @@ java_handle_option (size_t scode, const char *arg, int value) if (arg == NULL && (option->flags & (CL_JOINED | CL_SEPARATE))) { - /* These can take an empty argument. */ - if (code == OPT_fassume_compiled_ - || code == OPT_fclasspath_ - || code == OPT_fCLASSPATH_ - || code == OPT_fbootclasspath_) - arg = ""; - else - { - error ("missing argument to \"-%s\"", option->opt_text); - return 1; - } + error ("missing argument to \"-%s\"", option->opt_text); + return 1; } switch (code) diff --git a/gcc/java/lang.opt b/gcc/java/lang.opt index e108fb7..ed8d02e 100644 --- a/gcc/java/lang.opt +++ b/gcc/java/lang.opt @@ -65,7 +65,7 @@ Wredundant-modifiers Java fCLASSPATH= -Java Joined RejectNegative +Java JoinedOrMissing RejectNegative fassert Java @@ -74,16 +74,16 @@ fassume-compiled Java fassume-compiled= -Java Joined +Java JoinedOrMissing fbootclasspath= -Java Joined RejectNegative +Java JoinedOrMissing RejectNegative fcheck-references Java fclasspath= -Java Joined RejectNegative +Java JoinedOrMissing RejectNegative fcompile-resource= Java Joined RejectNegative -- cgit v1.1