Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add etl::duration? #785

Closed
jaskij opened this issue Nov 9, 2023 · 2 comments
Closed

Add etl::duration? #785

jaskij opened this issue Nov 9, 2023 · 2 comments

Comments

@jaskij
Copy link
Sponsor Contributor

jaskij commented Nov 9, 2023

Just today, I was greeted by a nasty message from GCC 13.2 that the <chrono> header (and thus everything in std::chrono) is not available in a freestanding implementation.

While that is true, it has worked in the past. Would it make sense to add an etl::duration? It's the part of it that previously worked, and the one most likely to be missed. An alternative option would be to encourage the use of a units library (either generally, or a specific one).

@jwellbelove
Copy link
Contributor

jwellbelove commented Nov 10, 2023

I started a feature branch a while ago (feature/#757-Add-time-date-classes) that I plan to gradually add to over time.

It currently just implements some of the basic chrono units:-

day
weekday
weekday_indexed
weekday_last
month
year
last_spec
duration

@jaskij
Copy link
Sponsor Contributor Author

jaskij commented Nov 10, 2023

Turns out it was just an issue with compilation flags (don't use -ffreestanding with GCC and newlib), so this issue is moot.

@jaskij jaskij closed this as completed Nov 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants