How to convert local_time to sys_time?

Feb 29, 2024 at 6:11pm
Hi,

I have this local time_point:

 
auto loc = std::chrono::current_zone()->to_local(std::chrono::system_clock::now());


and need to change it to sys_time -- maybe sys_seconds.

I have tried everything...


Regards,
Juan
Feb 29, 2024 at 6:33pm
Like this?

 
auto sys = std::chrono::current_zone()->to_sys(loc);
Last edited on Feb 29, 2024 at 6:33pm
Feb 29, 2024 at 10:23pm
thanks!!
Topic archived. No new replies allowed.