mirror of
https://github.com/intel/llvm.git
synced 2026-01-19 09:31:59 +08:00
Added the infrastructure necessary for plug-ins to be able to add their own settings instead of having settings added to existing ones. In particular "target.disable-kext-loading" was added to "target" where it should actually be specific to the the dynamic loader plugin. Now the plug-in manager has the ability to create settings at the root level starting with "plugin". Each plug-in type can add new sub dictionaries, and then each plug-in can register a setting dictionary under its own short name. For example the DynamicLoaderDarwinKernel plug-in now registers a setting dictionary at:
plugin
dynamic-loader
macosx-kernel
(bool) disable-kext-loading
To settings can be set using:
(lldb) settings set plugin.dynamic-loader.macosx-kernel.disable-kext-loading true
I currently only hooked up the DynamicLoader plug-ins, but the code is very easy to duplicate when and if we need settings for other plug-ins.
llvm-svn: 166294
This commit is contained in:
@@ -95,3 +95,15 @@ Properties::Apropos (const char *keyword, std::vector<const Property *> &matchin
|
||||
}
|
||||
return matching_properties.size();
|
||||
}
|
||||
|
||||
|
||||
lldb::OptionValuePropertiesSP
|
||||
Properties::GetSubProperty (const ExecutionContext *exe_ctx,
|
||||
const ConstString &name)
|
||||
{
|
||||
OptionValuePropertiesSP properties_sp (GetValueProperties ());
|
||||
if (properties_sp)
|
||||
return properties_sp->GetSubProperty (exe_ctx, name);
|
||||
return lldb::OptionValuePropertiesSP();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user