{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreifzel2nycatft33ftmcjgxyc7gguyolum4vjgdxixcjykiwwwtkxu",
    "uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mllxdtxk5s62"
  },
  "path": "/t/ann-interval-patterns-0-8-2/14044?page=2#post_21",
  "publishedAt": "2026-05-11T18:04:40.000Z",
  "site": "https://discourse.haskell.org",
  "textContent": "I wasn’t suggesting anything concrete - jusy musing on an old idea I never quite got working.\n\nThe main interpretation of a negative interval was as a negative (higher-kinded) number and then treated as a negative space (in my case). A mask over the interval was the practical idea, so interval 2 3 + interval 0 4 = interval 0 4 interval 2 3 + interval 4 0 = interval 4 0 in a convex hull union interpretation. I didn’t imply that code needs changing. I couldn’t quite make it work.\n\nThe main reason for my numhask-space library is to accomodate higher-kinded intervals, aka a rectangle composed of two intervals (interval 2 3, interval 0 4) and then unoin to calculate bounding rectangles (convex hulls) on 2d shapes for a chart library.\n\nA point or a surface doesn’t have a valid ord instance - you need a lattice approach - which is heading towards a pretty esoteric requirement.\n\nThe main idea I had with the interval-patterns api is whether you could use left and right associated operators, so\n\nSo union (2 :||: 5) (5 :<>:7) becomes\n\n⟦2 5⟧ ∪ ⟪5 7⟫ = ⟦2 7⟫\n\nThe symbols attach to the numbers ⟦2 5⟧ is function application and hence a blank.",
  "title": "[ANN] interval-patterns-0.8.2"
}