From: Wolfgang Bangerth Date: Sun, 17 Jun 2012 18:51:41 +0000 (+0000) Subject: Work around a problem with a zero-length array when dim==0. MSVC complains X-Git-Tag: v8.0.0~2499 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1cc96130ce5af76ddeb95796e71052c34d9368e;p=dealii.git Work around a problem with a zero-length array when dim==0. MSVC complains about that. (Patch by Bob Goodwin.) git-svn-id: https://svn.dealii.org/trunk@25633 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/include/deal.II/base/data_out_base.h b/deal.II/include/deal.II/base/data_out_base.h index 0c732bd7f7..d126f615aa 100644 --- a/deal.II/include/deal.II/base/data_out_base.h +++ b/deal.II/include/deal.II/base/data_out_base.h @@ -284,7 +284,11 @@ class DataOutBase * into neighborship of * sub-grid cells. */ - unsigned int neighbors[GeometryInfo::faces_per_cell]; + unsigned int neighbors[dim > 0 + ? + GeometryInfo::faces_per_cell + : + 1]; /** * Number of this