diff options
author | Tom de Vries <tom@codesourcery.com> | 2015-10-13 10:08:50 +0000 |
---|---|---|
committer | Tom de Vries <vries@gcc.gnu.org> | 2015-10-13 10:08:50 +0000 |
commit | d78182cc0ce05104e2f1cd40c97de974f075479f (patch) | |
tree | 89563bd3c31401b7aa9c038829d9746e20a87a34 /gcc/params.h | |
parent | 7fd103efccee2a5706df7ffafae9315995edd841 (diff) | |
download | gcc-d78182cc0ce05104e2f1cd40c97de974f075479f.zip gcc-d78182cc0ce05104e2f1cd40c97de974f075479f.tar.gz gcc-d78182cc0ce05104e2f1cd40c97de974f075479f.tar.bz2 |
Support DEFPARAMENUM in params.def
2015-10-13 Tom de Vries <tom@codesourcery.com>
* Makefile.in (PARAMS_H, PLUGIN_HEADERS): Add params-enum.h.
* params-enum.h: New file.
* opts.c (handle_param): Handle case that param arg is a string.
* params-list.h: Handle DEFPARAMENUM5 in params.def.
* params.c (find_param): New function, factored out of ...
(set_param_value): ... here.
(param_string_value_p): New function.
* params.h (struct param_info): Add value_names field.
(find_param, param_string_value_p): Declare.
From-SVN: r228755
Diffstat (limited to 'gcc/params.h')
-rw-r--r-- | gcc/params.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/params.h b/gcc/params.h index 9f7618a..1090d00 100644 --- a/gcc/params.h +++ b/gcc/params.h @@ -55,6 +55,9 @@ struct param_info /* A short description of the option. */ const char *const help; + + /* The optional names corresponding to the values. */ + const char **value_names; }; /* An array containing the compiler parameters and their current @@ -85,6 +88,9 @@ enum compiler_param LAST_PARAM }; +extern bool find_param (const char *, enum compiler_param *); +extern bool param_string_value_p (enum compiler_param, const char *, int *); + /* The value of the parameter given by ENUM. Not an lvalue. */ #define PARAM_VALUE(ENUM) \ ((int) global_options.x_param_values[(int) ENUM]) |