summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorjthorn <jthorn@17b73243-c579-4c4c-a9d2-2d5706c11dac>2006-02-09 13:00:58 +0000
committerjthorn <jthorn@17b73243-c579-4c4c-a9d2-2d5706c11dac>2006-02-09 13:00:58 +0000
commitf1616b9801380fecd8885f21cacae571a1c4a91c (patch)
treef2d2bc8ac108870da4a82db0a64dec6107bb22c2 /doc
parentc9175014622b007081c5becacb8a2a66d8ba5dfe (diff)
use size_t for 1-D array index in CCTK_GFINDEX3D example
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4252 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'doc')
-rw-r--r--doc/UsersGuide/ThornWriters.tex3
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/UsersGuide/ThornWriters.tex b/doc/UsersGuide/ThornWriters.tex
index 618a5dd0..0b2d7c10 100644
--- a/doc/UsersGuide/ThornWriters.tex
+++ b/doc/UsersGuide/ThornWriters.tex
@@ -1964,6 +1964,7 @@ this is generally the preferred form for general use.
\begin{figure}[bp]
\begin{verbatim}
+#include <stddef.h> /* defines size_t */
#include "cctk.h"
void MyThorn_MyFunction(CCTK_ARGUMENTS)
@@ -1976,7 +1977,7 @@ int i,j,k;
{
for (i = 0 ; i < cctk_lsh[0] ; ++i)
{
- const int posn = CCTK_GFINDEX3D(cctkGH, i,j,k);
+ const size_t posn = CCTK_GFINDEX3D(cctkGH, i,j,k);
/* calculate the global xyz coordinates of the (i,j,k) grid point */
/* (in a multipatch/multiblock context, this gives the per-patch coordinates) */