Path: ...!2.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.awk Subject: Re: Y2K38 bug (January 19, 2038) Date: Mon, 11 Mar 2024 08:14:40 -0700 Organization: None to speak of Lines: 31 Message-ID: <87il1sztpb.fsf@nosuchdomain.example.com> References: MIME-Version: 1.0 Content-Type: text/plain Injection-Info: dont-email.me; posting-host="803e1d91970c7135fb6b17cffb70db2d"; logging-data="3868047"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/UN6Tok9ciPh9exEUAWFM5" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) Cancel-Lock: sha1:Scnbi35LW0/Diorxat0DU8NLHEE= sha1:5haZE7fp1bCgSOek/vDs02VQ4dU= Bytes: 2204 "Mr. Man-wai Chang" writes: > On 9/3/2024 4:11 am, Kenny McCormack wrote: >> This is a non-issue in GAWK. Note that AWK in general does not have >> an >> integer type. It just has a "number" type - and that type is a C double. >> Observe: >> % gawk 'BEGIN { print strftime("%c",1e12)}' >> Thu Sep 26 19:46:40 33658 >> % >> So, I think we're good. > > Well, you can always outsource the job using system()! :) > > Year 2038 problem is not just a software issue. You also need 64-bit > CPU to compute dates. Awk is just a tool that makes use of operating > systems. > > Year 2038 problem - Wikipedia > It is just a software issue. Awk is implemented in C. ISO C has required 64-bit integer support since 1999. C specifies the time() function, and does not place restrictions on time_t or specify just how it represents times. POSIX currently does not require 64-bit time_t, but apparently will in its next edition. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com Working, but not speaking, for Medtronic void Void(void) { Void(); } /* The recursive call of the void */