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

feat: Support default zeros in 'nanoduration()' #105

Merged
merged 1 commit into from
Oct 14, 2022
Merged

feat: Support default zeros in 'nanoduration()' #105

merged 1 commit into from
Oct 14, 2022

Conversation

trevorld
Copy link
Contributor

  • Adds default zeros to nanoduration() in a reverse-compatible way
  • Can now do nanoduration(seconds = 20) instead of having to do nanoduration(hours = 0, minutes = 0, seconds = 20, nanoseconds = 0)

* Adds default zeros to `nanoduration()` in a reverse-compatible way
* Can now do `nanoduration(seconds = 20)` instead of having to do
  `nanoduration(hours = 0, minutes = 0, seconds = 20, nanoseconds = 0)`
Copy link
Owner

@eddelbuettel eddelbuettel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's another rather nice catch and I am now wondering why on earth we did not think about that.

Merging merging I want to give @lsilvest a chance to pipe though -- but LGTM!

@eddelbuettel
Copy link
Owner

@lsilvest -- if you have a moment a quick glancing review would be appreciated just in case.

I'll merge directly otherwise in a day or two.

@lsilvest
Copy link
Collaborator

That's another rather nice catch and I am now wondering why on earth we did not think about that.

Yes, looks like we don't use our own code enough :)

@eddelbuettel eddelbuettel merged commit bcabc41 into eddelbuettel:master Oct 14, 2022
@trevorld trevorld deleted the nanoduration-defaults branch October 15, 2022 05:48
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

Successfully merging this pull request may close these issues.

None yet

3 participants