[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [6531] Avoid comparing signed and unsigned (VZ)
From: |
Greg Chicares |
Subject: |
[lmi-commits] [6531] Avoid comparing signed and unsigned (VZ) |
Date: |
Sun, 27 Mar 2016 10:21:13 +0000 |
Revision: 6531
http://svn.sv.gnu.org/viewvc/?view=rev&root=lmi&revision=6531
Author: chicares
Date: 2016-03-27 10:21:12 +0000 (Sun, 27 Mar 2016)
Log Message:
-----------
Avoid comparing signed and unsigned (VZ)
Modified Paths:
--------------
lmi/trunk/multidimgrid_any.cpp
lmi/trunk/tier_view_editor.cpp
Modified: lmi/trunk/multidimgrid_any.cpp
===================================================================
--- lmi/trunk/multidimgrid_any.cpp 2016-03-26 23:40:20 UTC (rev 6530)
+++ lmi/trunk/multidimgrid_any.cpp 2016-03-27 10:21:12 UTC (rev 6531)
@@ -1418,8 +1418,8 @@
void MultiDimAxisAnyChoice::SelectionChanged()
{
- unsigned int const sel = GetSelection();
- if(!(0 <= sel && sel < axis_.GetCardinality()))
+ int const sel = GetSelection();
+ if(!(0 <= sel && sel < static_cast<int>(axis_.GetCardinality())))
{
fatal_error()
<< "The axis is inconsistent with its choice control."
Modified: lmi/trunk/tier_view_editor.cpp
===================================================================
--- lmi/trunk/tier_view_editor.cpp 2016-03-26 23:40:20 UTC (rev 6530)
+++ lmi/trunk/tier_view_editor.cpp 2016-03-27 10:21:12 UTC (rev 6531)
@@ -150,7 +150,7 @@
bool updated = false;
TierBandAxis& ba = static_cast<TierBandAxis&>(axis);
- if(ba.GetMinValue() != 0 || ba.GetMaxValue() < 0)
+ if(ba.GetMinValue() != 0 || ba.GetMaxValue() < ba.GetMinValue())
{
fatal_error()
<< "Band-axis adjuster has invalid limits."
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [lmi-commits] [6531] Avoid comparing signed and unsigned (VZ),
Greg Chicares <=