Commit e1b9ddb3 authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

Changed format %lu to %zu.

parent a9f2a9ef
...@@ -629,7 +629,7 @@ nodeType *expr_var_var(int init, int oper, nodeType *p1, nodeType *p2) ...@@ -629,7 +629,7 @@ nodeType *expr_var_var(int init, int oper, nodeType *p1, nodeType *p2)
static static
void ex_copy_var(int init, nodeType *p2, nodeType *p1) void ex_copy_var(int init, nodeType *p2, nodeType *p1)
{ {
if ( cdoVerbose ) cdoPrint("\t%s\tcopy\t%s[L%lu][N%lu] = %s[L%lu][N%lu]", if ( cdoVerbose ) cdoPrint("\t%s\tcopy\t%s[L%zu][N%zu] = %s[L%zu][N%zu]",
ExIn[init], p2->param.name, p2->param.nlev, p2->param.ngp, p1->param.name, p2->param.nlev, p2->param.ngp); ExIn[init], p2->param.name, p2->param.nlev, p2->param.ngp, p1->param.name, p2->param.nlev, p2->param.ngp);
size_t ngp = p1->param.ngp; size_t ngp = p1->param.ngp;
...@@ -662,7 +662,7 @@ void ex_copy_con(int init, nodeType *p2, nodeType *p1) ...@@ -662,7 +662,7 @@ void ex_copy_con(int init, nodeType *p2, nodeType *p1)
{ {
double cval = p1->u.con.value; double cval = p1->u.con.value;
if ( cdoVerbose ) cdoPrint("\t%s\tcopy\t%s[L%lu][N%lu] = %g", ExIn[init], p2->param.name, p2->param.nlev, p2->param.ngp, cval); if ( cdoVerbose ) cdoPrint("\t%s\tcopy\t%s[L%zu][N%zu] = %g", ExIn[init], p2->param.name, p2->param.nlev, p2->param.ngp, cval);
size_t ngp = p2->param.ngp; size_t ngp = p2->param.ngp;
assert(ngp > 0); assert(ngp > 0);
...@@ -722,19 +722,19 @@ nodeType *expr(int init, int oper, nodeType *p1, nodeType *p2) ...@@ -722,19 +722,19 @@ nodeType *expr(int init, int oper, nodeType *p1, nodeType *p2)
{ {
p = expr_var_var(init, oper, p1, p2); p = expr_var_var(init, oper, p1, p2);
if ( cdoVerbose ) if ( cdoVerbose )
cdoPrint("\t%s\tarith\t%s[L%lu][N%lu] = %s %s %s", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.var.nm, coper, p2->u.var.nm); cdoPrint("\t%s\tarith\t%s[L%zu][N%zu] = %s %s %s", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.var.nm, coper, p2->u.var.nm);
} }
else if ( p1->type == typeVar && p2->type == typeCon ) else if ( p1->type == typeVar && p2->type == typeCon )
{ {
p = expr_var_con(init, oper, p1, p2); p = expr_var_con(init, oper, p1, p2);
if ( cdoVerbose ) if ( cdoVerbose )
cdoPrint("\t%s\tarith\t%s[L%lu][N%lu] = %s %s %g", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.var.nm, coper, p2->u.con.value); cdoPrint("\t%s\tarith\t%s[L%zu][N%zu] = %s %s %g", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.var.nm, coper, p2->u.con.value);
} }
else if ( p1->type == typeCon && p2->type == typeVar ) else if ( p1->type == typeCon && p2->type == typeVar )
{ {
p = expr_con_var(init, oper, p1, p2); p = expr_con_var(init, oper, p1, p2);
if ( cdoVerbose ) if ( cdoVerbose )
cdoPrint("\t%s\tarith\t%s[L%lu][N%lu] = %g %s %s", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.con.value, coper, p2->u.var.nm); cdoPrint("\t%s\tarith\t%s[L%zu][N%zu] = %g %s %s", ExIn[init], p->u.var.nm, p->param.nlev, p->param.ngp, p1->u.con.value, coper, p2->u.var.nm);
} }
else if ( p1->type == typeCon && p2->type == typeCon ) else if ( p1->type == typeCon && p2->type == typeCon )
{ {
...@@ -969,7 +969,7 @@ nodeType *fun1c(int init, int funcID, nodeType *p1, double value, parse_param_t ...@@ -969,7 +969,7 @@ nodeType *fun1c(int init, int funcID, nodeType *p1, double value, parse_param_t
{ {
long ilevidx = lround(value); long ilevidx = lround(value);
if ( ilevidx < 1 || ilevidx > (long)nlev ) if ( ilevidx < 1 || ilevidx > (long)nlev )
cdoAbort("%s(): level index %ld out of range (range: 1-%lu)!", funcname, ilevidx, nlev); cdoAbort("%s(): level index %ld out of range (range: 1-%zu)!", funcname, ilevidx, nlev);
levidx = (size_t) ilevidx - 1; levidx = (size_t) ilevidx - 1;
} }
else if ( strcmp(funcname, "sellevel") == 0 ) else if ( strcmp(funcname, "sellevel") == 0 )
...@@ -1137,15 +1137,15 @@ nodeType *ex_ifelse(int init, nodeType *p1, nodeType *p2, nodeType *p3) ...@@ -1137,15 +1137,15 @@ nodeType *ex_ifelse(int init, nodeType *p1, nodeType *p2, nodeType *p3)
if ( cdoVerbose ) if ( cdoVerbose )
{ {
fprintf(stderr, "cdo expr:\t%s\tifelse\t%s[L%lu][N%lu] ? ", ExIn[init], p1->u.var.nm, p1->param.nlev, p1->param.ngp); fprintf(stderr, "cdo expr:\t%s\tifelse\t%s[L%zu][N%zu] ? ", ExIn[init], p1->u.var.nm, p1->param.nlev, p1->param.ngp);
if ( p2->type == typeCon ) if ( p2->type == typeCon )
fprintf(stderr, "%g : ", p2->u.con.value); fprintf(stderr, "%g : ", p2->u.con.value);
else else
fprintf(stderr, "%s[L%lu][N%lu] : ", p2->u.var.nm, p2->param.nlev, p2->param.ngp); fprintf(stderr, "%s[L%zu][N%zu] : ", p2->u.var.nm, p2->param.nlev, p2->param.ngp);
if ( p3->type == typeCon ) if ( p3->type == typeCon )
fprintf(stderr, "%g\n", p3->u.con.value); fprintf(stderr, "%g\n", p3->u.con.value);
else else
fprintf(stderr, "%s[L%lu][N%lu]\n", p3->u.var.nm, p3->param.nlev, p3->param.ngp); fprintf(stderr, "%s[L%zu][N%zu]\n", p3->u.var.nm, p3->param.nlev, p3->param.ngp);
} }
size_t nmiss1 = p1->param.nmiss; size_t nmiss1 = p1->param.nmiss;
...@@ -1377,9 +1377,9 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg) ...@@ -1377,9 +1377,9 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg)
if ( i < maxout || (ngp > maxout && i >= (ngp-maxout)) ) if ( i < maxout || (ngp > maxout && i >= (ngp-maxout)) )
{ {
if ( steptype == TIME_CONSTANT ) if ( steptype == TIME_CONSTANT )
fprintf(stdout, " %s[lev=%lu:gp=%lu] = %g\n", vname, k+1, i+1, data[k*ngp+i]); fprintf(stdout, " %s[lev=%zu:gp=%zu] = %g\n", vname, k+1, i+1, data[k*ngp+i]);
else else
fprintf(stdout, " %s[ts=%ld:lev=%lu:gp=%lu] = %g\n", vname, tsID, k+1, i+1, data[k*ngp+i]); fprintf(stdout, " %s[ts=%ld:lev=%zu:gp=%zu] = %g\n", vname, tsID, k+1, i+1, data[k*ngp+i]);
} }
else if ( i == maxout ) else if ( i == maxout )
{ {
...@@ -1514,7 +1514,7 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg) ...@@ -1514,7 +1514,7 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg)
p->param.nmiss = params[varID].nmiss; p->param.nmiss = params[varID].nmiss;
} }
if ( parse_arg->debug ) cdoPrint("\tpush\tvar\t%s[L%lu][N%lu]", vnm, p->param.nlev, p->param.ngp); if ( parse_arg->debug ) cdoPrint("\tpush\tvar\t%s[L%zu][N%zu]", vnm, p->param.nlev, p->param.ngp);
rnode = p; rnode = p;
...@@ -1577,7 +1577,7 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg) ...@@ -1577,7 +1577,7 @@ nodeType *expr_run(nodeType *p, parse_param_t *parse_arg)
if ( parse_arg->debug ) if ( parse_arg->debug )
{ {
if ( rnode && rnode->type == typeVar) if ( rnode && rnode->type == typeVar)
cdoPrint("\tpop\tvar\t%s[L%lu][N%lu]", varname2, rnode->param.nlev, rnode->param.ngp); cdoPrint("\tpop\tvar\t%s[L%zu][N%zu]", varname2, rnode->param.nlev, rnode->param.ngp);
else else
cdoPrint("\tpop\tconst\t%s", varname2); cdoPrint("\tpop\tconst\t%s", varname2);
} }
......
...@@ -27,7 +27,7 @@ void grid_store_init(grid_store_t* grid_store, long gridsize) ...@@ -27,7 +27,7 @@ void grid_store_init(grid_store_t* grid_store, long gridsize)
if ( grid_store->max_size%grid_store->blk_size > 0 ) grid_store->nblocks++; if ( grid_store->max_size%grid_store->blk_size > 0 ) grid_store->nblocks++;
if ( cdoVerbose ) if ( cdoVerbose )
fprintf(stdout, "blksize = %zu lastblksize = %zu max_size = %zu nblocks = %zu\n", fprintf(stdout, "blksize = %ld lastblksize = %ld max_size = %ld nblocks = %ld\n",
grid_store->blk_size, grid_store->max_size%grid_store->blk_size, grid_store->blk_size, grid_store->max_size%grid_store->blk_size,
grid_store->max_size, grid_store->nblocks); grid_store->max_size, grid_store->nblocks);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment