-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Support signbit(::Dates.Period)
#51073
Conversation
Seems somewhat reasonable, what's the motivating usecase for adding this feature? |
I don't have a very compelling use case, but I had noticed this when trying to construct an infinite range of dates (i.e. an arbitrarily long sequence of dates starting at a specified point). The current implementation of ranges in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, why not
@halleysfifthinc Could you elaborate why you dislike this proposal? |
This is completely my own interpretation, since the documentation doesn't explicitly state this, but I understood |
That being said, I understand the concern, but I wonder if we want to be strict about this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
signbit(x::Dates.Period)
signbit(::Dates.Period)
signbit(x)
is defined toSince
sign
is defined for aPeriod
, it makes sense forsignbit
to be defined as well. After this,