summaryrefslogtreecommitdiffstats
path: root/lldb/source/Breakpoint/Breakpoint.cpp
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2010-07-09 20:39:50 +0000
committerGreg Clayton <gclayton@apple.com>2010-07-09 20:39:50 +0000
commitc982c768d248b21b82fbd70b61a4cc824cd82ddc (patch)
tree68c5d417ce51994a2d393e5a5a7f0025b6e4ed35 /lldb/source/Breakpoint/Breakpoint.cpp
parent2a5725b1a324639d0e16e9c125f5713acfabca60 (diff)
downloadbcm5719-llvm-c982c768d248b21b82fbd70b61a4cc824cd82ddc.tar.gz
bcm5719-llvm-c982c768d248b21b82fbd70b61a4cc824cd82ddc.zip
Merged Eli Friedman's linux build changes where he added Makefile files that
enabled LLVM make style building and made this compile LLDB on Mac OS X. We can now iterate on this to make the build work on both linux and macosx. llvm-svn: 108009
Diffstat (limited to 'lldb/source/Breakpoint/Breakpoint.cpp')
-rw-r--r--lldb/source/Breakpoint/Breakpoint.cpp29
1 files changed, 16 insertions, 13 deletions
diff --git a/lldb/source/Breakpoint/Breakpoint.cpp b/lldb/source/Breakpoint/Breakpoint.cpp
index 12dceac7476..e11604ba22e 100644
--- a/lldb/source/Breakpoint/Breakpoint.cpp
+++ b/lldb/source/Breakpoint/Breakpoint.cpp
@@ -153,12 +153,12 @@ Breakpoint::IsEnabled ()
}
void
-Breakpoint::SetIgnoreCount (int32_t n)
+Breakpoint::SetIgnoreCount (uint32_t n)
{
m_options.SetIgnoreCount(n);
}
-int32_t
+uint32_t
Breakpoint::GetIgnoreCount () const
{
return m_options.GetIgnoreCount();
@@ -255,7 +255,7 @@ Breakpoint::ModulesChanged (ModuleList &module_list, bool load)
// them after the locations pass. Have to do it this way because
// resolving breakpoints will add new locations potentially.
- for (int i = 0; i < module_list.GetSize(); i++)
+ for (size_t i = 0; i < module_list.GetSize(); i++)
{
bool seen = false;
ModuleSP module_sp (module_list.GetModuleAtIndex (i));
@@ -263,9 +263,9 @@ Breakpoint::ModulesChanged (ModuleList &module_list, bool load)
if (!m_filter_sp->ModulePasses (module_sp))
continue;
- for (int i = 0; i < m_locations.GetSize(); i++)
+ for (size_t j = 0; j < m_locations.GetSize(); j++)
{
- BreakpointLocationSP break_loc = m_locations.GetByIndex(i);
+ BreakpointLocationSP break_loc = m_locations.GetByIndex(j);
const Section *section = break_loc->GetAddress().GetSection();
if (section == NULL || section->GetModule() == module)
{
@@ -300,15 +300,15 @@ Breakpoint::ModulesChanged (ModuleList &module_list, bool load)
// the same? Or do we need to do an equality on modules that is an
// "equivalence"???
- for (int i = 0; i < module_list.GetSize(); i++)
+ for (size_t i = 0; i < module_list.GetSize(); i++)
{
ModuleSP module_sp (module_list.GetModuleAtIndex (i));
if (!m_filter_sp->ModulePasses (module_sp))
continue;
- for (int i = 0; i < m_locations.GetSize(); i++)
+ for (size_t j = 0; j < m_locations.GetSize(); j++)
{
- BreakpointLocationSP break_loc = m_locations.GetByIndex(i);
+ BreakpointLocationSP break_loc = m_locations.GetByIndex(j);
const Section *section = break_loc->GetAddress().GetSection();
if (section)
{
@@ -353,8 +353,8 @@ Breakpoint::GetDescription (Stream *s, lldb::DescriptionLevel level, bool show_l
GetResolverDescription (s);
GetFilterDescription (s);
- const uint32_t num_locations = GetNumLocations ();
- const uint32_t num_resolved_locations = GetNumResolvedLocations ();
+ const size_t num_locations = GetNumLocations ();
+ const size_t num_resolved_locations = GetNumResolvedLocations ();
switch (level)
{
@@ -362,9 +362,9 @@ Breakpoint::GetDescription (Stream *s, lldb::DescriptionLevel level, bool show_l
case lldb::eDescriptionLevelFull:
if (num_locations > 0)
{
- s->Printf(", locations = %u", num_locations);
+ s->Printf(", locations = %zu", num_locations);
if (num_resolved_locations > 0)
- s->Printf(", resolved = %u", num_resolved_locations);
+ s->Printf(", resolved = %zu", num_resolved_locations);
}
else
{
@@ -387,12 +387,15 @@ Breakpoint::GetDescription (Stream *s, lldb::DescriptionLevel level, bool show_l
s->Indent();
GetOptions()->GetDescription(s, level);
break;
+
+ default:
+ break;
}
if (show_locations)
{
s->IndentMore();
- for (int i = 0; i < GetNumLocations(); ++i)
+ for (size_t i = 0; i < num_locations; ++i)
{
BreakpointLocation *loc = GetLocationAtIndex(i).get();
loc->GetDescription(s, level);
OpenPOWER on IntegriCloud