Give more hints in "option not found" error.

This commit is contained in:
Delapouite 2018-03-27 19:14:41 +02:00
parent 726dd8f0d8
commit fc3f0f40b7

View File

@ -43,7 +43,7 @@ void OptionManager::unregister_watcher(OptionManagerWatcher& watcher) const
struct option_not_found : public runtime_error
{
option_not_found(StringView name)
: runtime_error("option not found: " + name) {}
: runtime_error(format("option not found: '{}'. Use declare-option first", name)) {}
};
Option& OptionManager::get_local_option(StringView name)