Patch from dawn@burble.org:
GetSupportFileAtIndex(), GetNumSupportFiles(), FindSupportFileIndex(): Add API support for getting the list of files in a compilation unit. GetNumCompileUnits(), GetCompileUnitAtIndex(): Add API support for retrieving the compilation units in a module. llvm-svn: 152942
This commit is contained in:
@@ -266,6 +266,30 @@ SBModule::GetDescription (SBStream &description)
|
||||
return true;
|
||||
}
|
||||
|
||||
uint32_t
|
||||
SBModule::GetNumCompileUnits()
|
||||
{
|
||||
ModuleSP module_sp (GetSP ());
|
||||
if (module_sp)
|
||||
{
|
||||
return module_sp->GetNumCompileUnits ();
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
SBCompileUnit
|
||||
SBModule::GetCompileUnitAtIndex (uint32_t index)
|
||||
{
|
||||
SBCompileUnit sb_cu;
|
||||
ModuleSP module_sp (GetSP ());
|
||||
if (module_sp)
|
||||
{
|
||||
CompUnitSP cu_sp = module_sp->GetCompileUnitAtIndex (index);
|
||||
sb_cu.reset(cu_sp.get());
|
||||
}
|
||||
return sb_cu;
|
||||
}
|
||||
|
||||
size_t
|
||||
SBModule::GetNumSymbols ()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user