From 3efb3762fec1ef8f3a12d2c74e2d4f1309c1b588 Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Thu, 2 Aug 2018 11:04:43 +0200 Subject: [PATCH] Use common type in AssertIndexRange for the comparison --- include/deal.II/base/exceptions.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/include/deal.II/base/exceptions.h b/include/deal.II/base/exceptions.h index 6ff4068d00..9f01ac2012 100644 --- a/include/deal.II/base/exceptions.h +++ b/include/deal.II/base/exceptions.h @@ -1402,11 +1402,16 @@ namespace internal * fails. * * @ingroup Exceptions - * @author Guido Kanschat 2007 + * @author Guido Kanschat, Daniel Arndt, 2007, 2018 */ #define AssertIndexRange(index, range) \ Assert( \ - (index) < (range), \ + static_cast::type)>:: \ + type>(index) < \ + static_cast::type)>:: \ + type>(range), \ dealii::ExcIndexRangeType::type)>:: \ type>((index), 0, (range))) -- 2.39.5