You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/10/19 10:55:40 UTC

[GitHub] [incubator-nuttx] juniskane commented on pull request #4693: time:follow POSIX use int64_t to define time_t

juniskane commented on pull request #4693:
URL: https://github.com/apache/incubator-nuttx/pull/4693#issuecomment-946607463


   > > iirc the more recent versions of posix require it to be an integer. but i'm not aware of a version which requires signed.
   > 
   > Here the integer ahould mean signed, since other place use unsigned integer in the same page.
   
   Most recent version here:
   https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_types.h.html
   says "time_t shall be an integer type". (This is marked as C extension, because ISO C also allows floating point time_t)
   
   I fail to see how rest of page using unsigned integer could be relevant, as the technical term "integer type" has a precisely defined meaning in ISO 9899:1999 (C99 standard, incorporated to Open Group spec by reference) section 6.2.5, clause 17: "The type **char**, the signed and unsigned integer types, and the enumerated types are collectively called _integer types_. The integer and real floating types are collectively called _real types_."
   
   I haven't looked inside this commit, but the claim that this is needed to "follow POSIX" in commit message's summary line is incorrect.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org