Dual-Life / Time-Piece

Object Oriented time objects
Other
15 stars 33 forks source link

warning from blead with gcc #15

Closed jhi closed 9 years ago

jhi commented 9 years ago

Piece.xs:1037:29: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]

sizeof() is unsigned, so it should be cast to (int).

smith153 commented 9 years ago

Thanks for the report. I might be able to change len to unsigned itself. Man pages states lowest value returned from strftime() is 0.

jhi commented 9 years ago

On Tuesday-201506-09 9:51, Samuel Smith wrote:

Thanks for the report. I might be able to change len to unsigned itself. Man pages states lowest value returned from strftime() is 0.

Or, rather, it's a size_t, which is unsigned.

http://www.cplusplus.com/reference/ctime/strftime/

— Reply to this email directly or view it on GitHub https://github.com/rjbs/Time-Piece/issues/15#issuecomment-110362623.

smith153 commented 9 years ago

Changed to size_t in 1.31.