Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mpim-sw
cdo
Commits
8a0fe23e
Commit
8a0fe23e
authored
Oct 23, 2020
by
Uwe Schulzweida
Browse files
Added warn_unused to struct GridDesciption.
parent
bbb55def
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/griddes.cc
View file @
8a0fe23e
...
...
@@ -23,7 +23,6 @@
#include
<cdi.h>
#include
"cdo_options.h"
#include
"dmemory.h"
#include
"process_int.h"
#include
"cdo_cdi_wrapper.h"
#include
"griddes.h"
...
...
@@ -505,7 +504,7 @@ cdoDefineGrid(const char *pgridfile)
if
(
gridID
==
-
1
)
cdoAbort
(
"Invalid grid description file %s!"
,
filename
);
}
if
(
lalloc
)
F
ree
(
filename
);
if
(
lalloc
)
f
ree
(
filename
);
free
(
gridfile
);
return
gridID
;
...
...
src/griddes.h
View file @
8a0fe23e
...
...
@@ -23,7 +23,11 @@
constexpr
double
undef_grid_value
=
9.e20
;
struct
GridDesciption
struct
// GridDesciption
#ifdef __GNUG__
__attribute__
((
warn_unused
))
#endif
GridDesciption
{
std
::
vector
<
int
>
mask
;
std
::
vector
<
double
>
xvals
;
...
...
@@ -35,7 +39,7 @@ struct GridDesciption
double
xfirst
=
undef_grid_value
,
yfirst
=
undef_grid_value
;
double
xlast
=
undef_grid_value
,
ylast
=
undef_grid_value
;
double
xinc
=
undef_grid_value
,
yinc
=
undef_grid_value
;
double
xpole
=
0
,
ypole
=
0
,
angle
=
0
;
// rotated north pole
double
xpole
=
0.
0
,
ypole
=
0.
0
,
angle
=
0.
0
;
// rotated north pole
int
scanningMode
=
64
;
/*
scanningMode = 128 * iScansNegatively + 64 * jScansPositively + 32 * jPointsAreConsecutive;
...
...
@@ -44,7 +48,7 @@ struct GridDesciption
96 = 128 * 0 + 64 * 1 + 32 * 1
Default implicit scanning mode is 64: i and j scan positively, i points are consecutive (row-major)
*/
double
a
=
0
;
double
a
=
0.
0
;
int
isRotated
=
0
;
// true for rotated grids
int
datatype
=
CDI_UNDEFID
;
int
type
=
CDI_UNDEFID
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment