diff options
author | allen <allen@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2001-05-10 16:42:50 +0000 |
---|---|---|
committer | allen <allen@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2001-05-10 16:42:50 +0000 |
commit | 3031db85e40f458dc9515fbaf908991278131b58 (patch) | |
tree | 9536c1b37ddc97c703506886d7249b9438af6d43 /src/main/Groups.c | |
parent | 9715b4970c9ffe5472ed0d52a7b0a83e841b00df (diff) |
CCTKi_CreateGroup returns an error code for GFs from mixed dims.
I'm actually trapping it in the CST generated code, which maybe isn't
the best place.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@2162 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/main/Groups.c')
-rw-r--r-- | src/main/Groups.c | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/main/Groups.c b/src/main/Groups.c index 2ca4d336..2989d4d7 100644 --- a/src/main/Groups.c +++ b/src/main/Groups.c @@ -152,6 +152,7 @@ static int total_variables = 0; static int *group_of_variable = NULL; static int maxdim = 0; +static int gfdim = 0; static int staggered = 0; @@ -1810,6 +1811,23 @@ int CCTKi_CreateGroup (const char *gname, group->size = CCTKi_ExtractSize (dimension, thorn, size); group->ghostsize = CCTKi_ExtractSize (dimension, thorn, ghostsize); } + + /* Only typically have GFs in a single dimension */ + if (group->gtype == CCTK_GF) + { + if (gfdim > 0) + { + if (group->dim != gfdim) + { + retval = 1; + } + } + else + { + gfdim = group->dim; + } + } + } else { @@ -1818,7 +1836,7 @@ int CCTKi_CreateGroup (const char *gname, if (retval) { - CCTK_Warn (4, __LINE__, __FILE__, "Cactus", "CCTK_CreateGroup: Error"); + CCTK_Warn (4, __LINE__, __FILE__, "Cactus", "CCTKi_CreateGroup: Error"); } return (retval); |