-
Notifications
You must be signed in to change notification settings - Fork 1
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
Consider an API more in line with the Rust API guidelines #2
Comments
Makes sense. I did not think much, about this. I just copied what's in chrono :) |
Yup, like I said what you did makes sense, it's just unfortunate that chrono's api is so unrusty. |
Hey @kosta I just came across this project and it's been helpful for me in my work. Are you still working to maintain it? Will you be open to PRs to your repository? (Apologies for communicating over an issue, I couldn't find any other place to get in touch with you.) |
Hi!
This repo is just a fork to be merged back into chrono. I wish to modify the API heavily and integrate into chrono, e.g. overloading std::ops::Add etc.
But as you can see, I was pretty lazy in the past months... I hope I can move this forward in September.
That being said, there are a couple of other similar approaches, e.g. kairos (search for it on GitHub, I’m on mobile right now)
Cheers,
Kosta
… Am 01.08.2018 um 05:56 schrieb Mayur ***@***.***>:
Hey @kosta I just came across this project and it's been helpful for me in my work. Are you still working to maintain it? Will you be open to PRs to your repository?
(Apologies for communicating over an issue, I couldn't find any other place to get in touch with you.)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
@kosta Thanks for writing in. Yes, I saw the issues on this repo and that you wanted to change the API to match Rust styling. This is why I was hoping I could contribute to the repository if you'd like. Let me know if this is something you might be interested in. Thanks for your time! 😃 |
@mayurdzk I'm currently experimenting with a better code structure and need to figure out if this works. When I have a prototype I would appreciate your feedback! |
Your API imitates Chrono's (which makes sense) with constructors like
::days()
, but it's much more common in rust to have names like::from_days()
for static constructors.Chrono is pretty old, and contains some styles that are unexpected to modern Rust programmers. I hope to migrate chrono to something that will cause less confusion for our users.
The text was updated successfully, but these errors were encountered: