aboutsummaryrefslogtreecommitdiff
path: root/gold/parameters.cc
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@google.com>2008-03-04 23:10:38 +0000
committerIan Lance Taylor <iant@google.com>2008-03-04 23:10:38 +0000
commitee1fe73e110f7009719b6befefd9fabe94672931 (patch)
tree10b08a9e267cbba7127112fef725dac0dd8f96df /gold/parameters.cc
parent3954eb47e14c40e07db4ada5069debdc6fd1ae93 (diff)
downloadgdb-ee1fe73e110f7009719b6befefd9fabe94672931.zip
gdb-ee1fe73e110f7009719b6befefd9fabe94672931.tar.gz
gdb-ee1fe73e110f7009719b6befefd9fabe94672931.tar.bz2
From Craig Silverstein: rework option handling to make it easier to
add a new option.
Diffstat (limited to 'gold/parameters.cc')
-rw-r--r--gold/parameters.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/gold/parameters.cc b/gold/parameters.cc
index fdd5fd7..f240c1d 100644
--- a/gold/parameters.cc
+++ b/gold/parameters.cc
@@ -22,6 +22,7 @@
#include "gold.h"
+#include "debug.h"
#include "options.h"
#include "target.h"
#include "target-select.h"
@@ -41,8 +42,9 @@ Parameters::set_options(const General_options* options)
{
gold_assert(!this->options_valid());
this->options_ = options;
- // For speed, we make our own copy of the debug variable.
- this->debug_ = this->options().debug();
+ // For speed, we convert the options() debug var from a string to an
+ // enum (from debug.h).
+ this->debug_ = debug_string_to_enum(this->options().debug());
}
void