Skip to content

Commit

Permalink
Re #4266 Fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mdoucet committed Dec 12, 2011
1 parent 5e018e6 commit 0aa8ad1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Code/Mantid/Framework/API/src/TempFunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ namespace API
FunctionDomain(n)
{
// n > 0, FunctionDomain(n) must throw if it isn't
double dx = (end - start) / (n - 1);
double dx = (end - start) / (static_cast<double>(n) - 1.0);
m_X.resize(n);
double x = start;
for(size_t i = 0; i < n; ++i, x += dx)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ namespace Algorithms
// ii. search
abstimeit = std::lower_bound(mSETimes.begin()+posoffset, mSETimes.end(), mtime);
size_t mindex = size_t(abstimeit-mSETimes.begin())-1;
if (mindex < 0 || mindex >= mSETimes.size())
if (mindex >= mSETimes.size())
throw std::invalid_argument("Flag 1616: Wrong in searching!!!");
else
posoffset += mindex;
Expand Down

0 comments on commit 0aa8ad1

Please sign in to comment.