From 4f0f69930855685a65e147b80aaa175e18efcf67 Mon Sep 17 00:00:00 2001 From: kanschat Date: Mon, 22 Mar 2010 20:23:41 +0000 Subject: [PATCH] Assertion added git-svn-id: https://svn.dealii.org/trunk@20882 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/base/include/base/exceptions.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/deal.II/base/include/base/exceptions.h b/deal.II/base/include/base/exceptions.h index 95b1c3a4f9..c441f31e29 100644 --- a/deal.II/base/include/base/exceptions.h +++ b/deal.II/base/include/base/exceptions.h @@ -2,7 +2,7 @@ // $Id$ // Version: $Name$ // -// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009 by the deal.II authors +// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009, 2010 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -947,10 +947,21 @@ namespace StandardExceptions * * @ingroup Exceptions * @author Guido Kanschat 2007 -*/ + */ #define AssertDimension(dim1,dim2) Assert((dim1) == (dim2), \ ExcDimensionMismatch((dim1),(dim2))) +/** + * Special assertion, testing whether vec has size + * dim1, and each entry of the vector has the + * size dim2 + * + * @ingroup Exceptions + * @author Guido Kanschat 2010 +*/ +#define AssertVectorVectorDimension(vec,dim1,dim2) AssertDimension((vec).size(), (dim1)) \ + for (unsigned int i=0;i