Opened 14 months ago
Closed 12 months ago
#31717 closed defect (fixed)
Empty families should be false
Reported by: | mkoeppe | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | sage-9.4 |
Component: | combinatorics | Keywords: | |
Cc: | tscrim | Merged in: | |
Authors: | Travis Scrimshaw | Reviewers: | Matthias Koeppe |
Report Upstream: | N/A | Work issues: | |
Branch: | 42abda7 (Commits, GitHub, GitLab) | Commit: | 42abda7c927e2db4378cdaf4af27315c6669d62b |
Dependencies: | Stopgaps: |
Description
sage: Family([]) Family () sage: bool(_) True
Compare with:
sage: bool(dict()) False
Change History (7)
comment:1 Changed 14 months ago by
- Branch set to public/sets/trivial_family_bool-31717
- Commit set to cbbef90cc8caacb6bafbe2c0cb32d40bfe5a4f4b
- Status changed from new to needs_review
comment:2 Changed 14 months ago by
Shouldn't there also be a change for FiniteFamily
?
comment:3 Changed 14 months ago by
- Commit changed from cbbef90cc8caacb6bafbe2c0cb32d40bfe5a4f4b to 42abda7c927e2db4378cdaf4af27315c6669d62b
Branch pushed to git repo; I updated commit sha1. New commits:
42abda7 | Adding __bool__ for other families.
|
comment:4 Changed 14 months ago by
Indeed, there should be. I also added one for LazyFamily
.
comment:5 Changed 14 months ago by
- Reviewers set to Matthias Koeppe
- Status changed from needs_review to positive_review
This works well, thanks a lot
comment:6 Changed 14 months ago by
No problem. Thanks for the review.
comment:7 Changed 12 months ago by
- Branch changed from public/sets/trivial_family_bool-31717 to 42abda7c927e2db4378cdaf4af27315c6669d62b
- Resolution set to fixed
- Status changed from positive_review to closed
Note: See
TracTickets for help on using
tickets.
I added the simple
__bool__
check to the appropriate class:New commits:
Adding a __bool__ to trivial family.