diff options
author | tradke <tradke@d60812e6-3970-4df4-986e-c251b06effeb> | 2003-03-10 13:10:47 +0000 |
---|---|---|
committer | tradke <tradke@d60812e6-3970-4df4-986e-c251b06effeb> | 2003-03-10 13:10:47 +0000 |
commit | f69684d7aba78edce0e0465e8ba338ae19a1e4b7 (patch) | |
tree | a1dcfc5e5c9db511b4129a7b637a5c8d2f2a419d /src/pugh_reductions.h | |
parent | 5a55318a46ef9e35ff93d0b36bd4053a1734c61a (diff) |
Almost forgot to commit this: added 'const' qualifiers to all the read-only
input arguments for the reduction API.
You also need an up-to-date flesh now in order to compile.
git-svn-id: http://svn.cactuscode.org/arrangements/CactusPUGH/PUGHReduce/trunk@35 d60812e6-3970-4df4-986e-c251b06effeb
Diffstat (limited to 'src/pugh_reductions.h')
-rw-r--r-- | src/pugh_reductions.h | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/src/pugh_reductions.h b/src/pugh_reductions.h index af7586a..88a52a4 100644 --- a/src/pugh_reductions.h +++ b/src/pugh_reductions.h @@ -1,11 +1,11 @@ /*@@ @header pugh_reductions.h @date April 29 1999 - @author Gabrielle - @desc - Prototypes for pugh reduction operators - @enddesc - @version $Header$ + @author Gabrielle Allen + @desc + Prototypes for pugh reduction operators + @enddesc + @version $Header$ @@*/ #ifndef _PUGH_REDUCTIONS_H_ @@ -63,7 +63,7 @@ outvals_type, outvals, num_outvals, total_outvals) \ { \ int _i, _j, _dim, _vindex; \ - cctk_type *typed_vdata = (cctk_type *) (vdata); \ + const cctk_type *typed_vdata = (vdata); \ outvals_type typed_outval; \ \ \ @@ -147,35 +147,35 @@ int PUGH_ReductionNorm1Arrays (REDUCTION_ARRAY_OPERATOR_REGISTER_ARGLIST); int PUGH_ReductionNorm2Arrays (REDUCTION_ARRAY_OPERATOR_REGISTER_ARGLIST); int PUGH_ReductionNormInfArrays (REDUCTION_ARRAY_OPERATOR_REGISTER_ARGLIST); -typedef int (*reduction_fn_t) (cGH *GH, +typedef int (*reduction_fn_t) (const cGH *GH, int proc, int num_dims, - int from[/* dim */], - int to[/* dim */], + const int from[/* dim */], + const int to[/* dim */], int iterator[/* dim */], - int points_per_dim[/* dim */], + const int points_per_dim[/* dim */], int num_points, int num_inarrays, - int intypes[/* num_inarrays */], - void *inarrays[/* num_inarrays */], + const int intypes[/* num_inarrays */], + const void *const inarrays[/* num_inarrays */], int num_outvals, CCTK_REAL outvals[/*num_inarrays*num_outvals*/]); -int PUGH_ReductionGVs (cGH *GH, +int PUGH_ReductionGVs (const cGH *GH, int proc, int num_invars, - int invars[/* num_invars */], + const int invars[/* num_invars */], int outtype, int num_outvals, void *outvals /* [num_outvals] */, reduction_fn_t reduction_fn); -int PUGH_ReductionArrays (cGH *GH, +int PUGH_ReductionArrays (const cGH *GH, int proc, int num_dims, - int dims[/* num_dims */], + const int dims[/* num_dims */], int intype, int num_inarrays, - void *inarrays[/* num_inarrays */], + const void *const inarrays[/* num_inarrays */], int outtype, int num_outvals, void *outvals /* [num_outvals] */, |