[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[UDUNITS #QVW-190351]: ut_get_converter and constness of args.



Erik,

> Was really intended for the arguments of ut_get_converter to be const pointers
> to ut_units or should it be pointers to const ut_units?
> 
> cv_converter*
> ut_get_converter(
> ut_unit* const      from,
> ut_unit* const      to);

The ut_unit structures can be modified by this function, so the structures 
can't be "const".  The "const"s that are in the declaration are a result of 
copying the function definition from the relevant .c file.

> Erik
> 
> - --
> Erik Zeek                     |  \|/ ____ \|/
> SMTS, Org 5444, MS-1153       |  "@'/ .. \`@"
> Sandia National Laboratories  |  /_| \__/ |_\
> Phone: 505-845-0513           |     \__U_/
> 
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.10 (GNU/Linux)
> 
> iEYEARECAAYFAkpwoSIACgkQheDjW4eQKVbD7wCffpsUikdO/6d9xMIuP9UcKsqP
> XnYAoL8gvD6vHDpLnceg9mv8QFwWMw7M
> =aSgC
> -----END PGP SIGNATURE-----


Regards,
Steve Emmerson

Ticket Details
===================
Ticket ID: QVW-190351
Department: Support UDUNITS
Priority: Normal
Status: Closed