haskell-unordered-containers / unordered-containers

Efficient hashing-based container types
BSD 3-Clause "New" or "Revised" License
222 stars 97 forks source link

Make debug flag manual #482

Closed phadej closed 2 months ago

phadej commented 10 months ago

By default flags are automatic. The debug flag is intended to be enabled manually, it seems bizarre to allow solvers to flip it.

konsumlamm commented 10 months ago

So actually this makes the debug flag manual (and not automatic, as the title/commit says).

phadej commented 10 months ago

So actually this makes the debug flag manual (and not automatic, as the title/commit says).

Yes

phadej commented 8 months ago

ping

treeowl commented 8 months ago

Who's being pinged?

phadej commented 8 months ago

Maintainers of unordered-containers.

treeowl commented 8 months ago

This seems reasonable on its surface, but I don't know enough about cabal. So a couple quick questions before I merge:

  1. How could it be flipped automatically?
  2. Why do we want to forbid automatic flipping? Is that a performance issue? A correctness issue?
phadej commented 8 months ago

How could it be flipped automatically?

By a solver.

Why do we want to forbid automatic flipping?

Because the flip to debug may happen unattendedly. debug has performance implications.

treeowl commented 8 months ago

How could it be flipped automatically?

By a solver.

Would you mind expanding on this just a little for my own education? What is a solver, exactly, and how would I end up with one that flips debug flags?

phadej commented 2 months ago

What is a solver, exactly, and how would I end up with one that flips debug flags?

Dependency solver. You may not, some other people may.

But I'm not keen on pushing this through anymore. May the solver flip flags on its will.