Le 25/05/2010 17:45, Poilbarbe Philippe a écrit :
> Hello,
>
> Another question.
> When I try to parse the unit "meter @ 100 @ 10" using
> ut_parse a NULL pointer is returned. It is normal according
> to the grammar, the unit should have been written as
> "(meter @100) @ 10".
>
> But my program try to explain why there is an error by
> using the ut_get_status() function. I filter UT_SYNTAX
> and UT_UNKNOWN which are user errors from others
> which are 'system' or 'program' error.
> But what is returned by ut_get_status() is UT_SUCCESS.
>
> Is it normal, or do I miss something ?
>
> Thanks again,
> Philippe
>
I was too prompt... It seems that any syntax error returns UT_SUCCESS:
'm/s )'
'm @ 10s'
'm since 1950-01-01 00:00:00'
As examples.
the UT_UNKNOWN status is returned correctly when an unknown name is used.
Ph.P.