Re: mbstowcs(3) may not return -1
In article <4FE340FF.80406@gmail.com>, demelier.david@gmail.com writes:
>On 21/06/2012 14:55, Sergey Kandaurov wrote:
>> It returns (size_t)(-1).
>> I don't know how is it correct, but this conforms to C spec.
>Mm, if I understand well, since it is cast to size_t, I think the return
>value will be SIZE_MAX - 1 then, right?
No. C does not make any such equivalence. "(size_t)-1" is the one
correct spelling of this value (modulo redundant additional
parentheses), and that's how the standard writes it.
-GAWollman
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
討論串 (同標題文章)
完整討論串 (本文為第 6 之 6 篇):