Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Fix typespecs for beginning_of_week and friends #315
Summary of changes
When running dialyzer against my project, I discovered that the type spec for
But the typespec only allows for
Further investigation indicates that the same issue affects
There's not really a way to write tests for this that I can think of, but before making my changes, running
After making these changes, those two warnings are gone.
Similarly, in my project I was getting these warnings for this code:
def for_current_status(today \\ local_today()) do Timex.beginning_of_week(today, :fri) end
Those warnings are now gone with these changes.
An interesting side note: