Re: mbstowcs(3) may not return -1

看板FB_current作者時間13年前 (2012/06/22 04:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串6/6 (看更多)
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"
文章代碼(AID): #1FuuJ2B5 (FB_current)
文章代碼(AID): #1FuuJ2B5 (FB_current)