aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/Eigen/CXX11/src/ThreadPool
diff options
context:
space:
mode:
authorGravatar Eugene Zhulenev <ezhulenev@google.com>2019-02-14 10:40:21 -0800
committerGravatar Eugene Zhulenev <ezhulenev@google.com>2019-02-14 10:40:21 -0800
commit7b837559a76171a6cd2b9341fdfaec75f8aaf6c3 (patch)
treee5ca89f5782747817814346ec54f83b59365d08a /unsupported/Eigen/CXX11/src/ThreadPool
parentf0d42d22656486812c1621b2426256765e1924fb (diff)
Fix signed-unsigned return in RuqQueue
Diffstat (limited to 'unsupported/Eigen/CXX11/src/ThreadPool')
-rw-r--r--unsupported/Eigen/CXX11/src/ThreadPool/RunQueue.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/unsupported/Eigen/CXX11/src/ThreadPool/RunQueue.h b/unsupported/Eigen/CXX11/src/ThreadPool/RunQueue.h
index 7a3be25e7..ecdc35f81 100644
--- a/unsupported/Eigen/CXX11/src/ThreadPool/RunQueue.h
+++ b/unsupported/Eigen/CXX11/src/ThreadPool/RunQueue.h
@@ -208,7 +208,7 @@ class RunQueue {
return CalculateSize(front, back);
} else {
// This value will be 0 if the queue is empty, and undefined otherwise.
- int maybe_zero = ((front ^ back) & kMask2);
+ unsigned maybe_zero = ((front ^ back) & kMask2);
eigen_assert(maybe_zero == 0 ? CalculateSize(front, back) == 0 : true);
return maybe_zero;
}
@@ -225,7 +225,7 @@ class RunQueue {
// increment size before the corresponding pop has decremented it.
// So the computed size can be up to kSize + 1, fix it.
if (size > static_cast<int>(kSize)) size = kSize;
- return size;
+ return static_cast<unsigned>(size);
}
RunQueue(const RunQueue&) = delete;