`length` returns negative values for decreasing continuous domains
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 67/100
Research direction
Start by locating the implementation of length for continuous intervals and the tests covering intervals with decreasing domains. Reproduce the example using std::greater and confirm the current negative result. Done when the length is positive for the reported interval and a regression test covers it.
Written by the indexing model from the issue text.
Description
As shown at https://godbolt.org/z/KTP4bG5s4:
#include <boost/icl/interval.hpp>
#include <functional>
#include <iostream>
int main()
{
using interval = boost::icl::continuous_interval<double, std::greater>;
interval x = interval::closed(5.0, 3.0);
std::cout << length(x) << "\n"; // outputs -2, should be 2
}
- Dominant language
- C++
- Stars
- 15
- Forks
- 51
- Avg merge
- 8d 6h
- Merged PRs (30d)
- 1
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from boostorg/icl
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
sprintf deprecatedOpen
Difficulty 1/5 Under an hour Newbie friendliness 62/100
-
Difficulty 3/5 1-2 days Newbie friendliness 56/100
-
`touches` is poorly specifiedPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 4/5 3-5 days Newbie friendliness 42/100
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
Similar issues
-
agent:WSL code-review linux pri:medium refactoring
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
kind/enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 1-3 hours Newbie friendliness 82/100
psi29a/d2decomped#691 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
CachyOS/packageinstaller#144 ·
Maintainers usually reply within 1 day
-
(S1 - Need confirmation)
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
CleverRaven/Cataclysm-DDA#89715 ·
Maintainers usually reply within 1 day