{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreihpenimonez2vek4uujugqjcjh46h4klkfwssnm5ejglhycp65qpe",
"uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mlkvsjemh4l2"
},
"path": "/t/ann-interval-patterns-0-8-2/14044#post_17",
"publishedAt": "2026-05-11T07:03:50.000Z",
"site": "https://discourse.haskell.org",
"tags": [
"@mixphix"
],
"textContent": "Good point: The interval-using community should discuss what uses there are for “non-normalized” intervals, as you call them, and how libraries should treat them. Guarding every function against `lower x > upper x` can lead to complicated interfaces, silent bugs or run-time crashes, depending on the choice of the library author.\nIn what circumstances is it suitable to keep computing with such an interval and what operations still turn up sensible results? For example, concerning overlap queries any such interval could be regarded as either the empty set (see Python ranges) or as the disjoint union of two rays. It seems that @mixphix calculates\n\n\n adjacency (interval 2 3) i2@(interval 4 0) =\n Contains (interval 2 4) i2 (interval 0 3)\n\n\nwhich I have a hard time interpreting because there is no documentation for the three arguments of `Contains`.",
"title": "[ANN] interval-patterns-0.8.2"
}