Hi,

2009/7/29 Glynn Clements <[email protected]>:
> The ->answer field in "struct Option" is a char*; it can only hold a
> string. Similarly, that's all that g.parser can pass to a script. It's
> up to the module or script to parse these to integers or floats where
> appropriate.

would make sense to change it in GRASS 7, e.g. option->answer as
'union' (int, double, char *). In this regard also check given value
by the parser. Then the parser could print a warning when the user
enter option value which cannot be casted to the given data type (e.g.
string for integer option).

Martin

-- 
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to