> > Why don't you use "d + relativedelta(day=-1)" instead? > > > > Just as easy to use, better error detection, and a big precedent. > > Supporting this might be cool indeed. OTOH, it doesn't replace the > current behavior. How do you get (day=30)? I don't follow. The semantics would be similar to list indexing. `day=30` asks for the 30-est day of the month and raises an ValueError if there isn't any. `day=-1` asks for the last day of the month (and should never raise an error <wink>). The allowed argument range for `day` would be between 1 and `n` with `n` the number of days in the month for positive values and between -1 and `-n` for negative values. -- Christian Tanzer http://www.c-tanzer.at/
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4