home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.c      Meh, in C you gotta define EVERYTHING      243,242 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 242,873 of 243,242   
   Tim Rentsch to James Kuyper   
   Re: printf and time_t   
   07 Jan 26 05:02:39   
   
   From: tr.17687@z991.linuxsc.com   
      
   James Kuyper  writes:   
      
   > On 2026-01-05 03:17, Andrey Tarasevich wrote:   
   >   
   >> On Sun 1/4/2026 11:19 PM, Kenny McCormack wrote:   
   >>   
   >>> The question is:  How can you reliably printf() a time_t value?   
   >>> What conversion spec should you use?   
   >>   
   >> You can't.  As far as the language is concerned, `time_t` is intended   
   >> to be an opaque type.  It has to be a real type, ...   
   >   
   > In C99, it was only required to be an arithmetic type.  I pointed out   
   > that this would permit it to be, for example, double _Imaginary. [...]   
      
   It's hard to imagine how time_t being an imaginary type could   
   provide the semantics described in the C standard for time_t.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca