{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreifv73upo3tl3gwct72fk2br6e2oyt3jdemmavgz2ptxk76drxp35m",
    "uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mhfufscc2lo2"
  },
  "path": "/t/type-level-programming-dealing-with-ambiguous-type-error/13828#post_3",
  "publishedAt": "2026-03-19T09:04:20.000Z",
  "site": "https://discourse.haskell.org",
  "textContent": "`AllowAmbiguousTypes` will just push the logical problem elsewhere. A required type argument won’t help because `x` is highly dynamic.\n\nThere seems to be two possible approaches here:\n\n  1. Somehow get the compiler to understand the relationship between `m`, `n` and `x` in the way that it can work here. This is my preferece, but I’m open to the fact that it might not be possible.\n\n  2. Thread through a singleton for `x`. This is complicated by the fact that it is not trivial to know what `x` is at any given point. I think I will try implementing an algorithm that passes `x` in the dumb-list version of my machine.\n\n\n",
  "title": "Type level programming: Dealing with ambiguous type error"
}