Commit 75f051b3 authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

Added enum.

parent be940292
......@@ -290,7 +290,7 @@ int params_add_ts(parseParamType *parse_arg)
params[varID].gridID = parse_arg->pointID;
params[varID].zaxisID = parse_arg->surfaceID;
params[varID].steptype = TIME_VARYING;
params[varID].ngp = 3;
params[varID].ngp = CLEN;
params[varID].nlev = 1;
parse_arg->nparams++;
......@@ -596,10 +596,10 @@ void *Expr(void *argument)
vdate0 = vdate;
vtime0 = vtime;
params[vartsID].data[0] = tsID+1;
params[vartsID].data[1] = vdate;
params[vartsID].data[2] = vtime;
params[vartsID].data[3] = jdelta;
params[vartsID].data[CTIMESTEP] = tsID+1;
params[vartsID].data[CDATE] = vdate;
params[vartsID].data[CTIME] = vtime;
params[vartsID].data[CDELTAT] = jdelta;
taxisCopyTimestep(taxisID2, taxisID1);
......
......@@ -69,10 +69,10 @@ static double pt_ngp(paramType *p) { return p->ngp; }
static double pt_nlev(paramType *p) { return p->nlev; }
static double pt_size(paramType *p) { return p->ngp*p->nlev; }
static double pt_missval(paramType *p) { return p->missval; }
static double ts_ctimestep(double *data) { return lround(data[0]); }
static double ts_cdate(double *data) { return lround(data[1]); }
static double ts_ctime(double *data) { return lround(data[2]); }
static double ts_cdeltat(double *data) { return data[3]; }
static double ts_ctimestep(double *data) { return lround(data[CTIMESTEP]); }
static double ts_cdate(double *data) { return lround(data[CDATE]); }
static double ts_ctime(double *data) { return lround(data[CTIME]); }
static double ts_cdeltat(double *data) { return data[CDELTAT]; }
typedef struct {
int type;
......
......@@ -24,6 +24,8 @@ int fileno(FILE *stream);
extern int CDO_parser_errorno;
enum {CTIMESTEP, CDATE, CTIME, CDELTAT, CLEN};
typedef enum { typeCon, typeVar, typeFun, typeFun1c, typeOpr, typeCom } nodeEnum;
// commands
......
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