HOL icon indicating copy to clipboard operation
HOL copied to clipboard

Use an efficient datastructure for substitution

Open GallagherCommaJack opened this issue 8 years ago • 2 comments

Currently, functions like match_term return substitutions represented as a list of pairs. Why don't all these functions use maps instead of lists?

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

GallagherCommaJack avatar Apr 09 '16 02:04 GallagherCommaJack

Historical reasons, mainly. Do you have an application needing a huge number of substitutions?

Konrad.

On Fri, Apr 8, 2016 at 9:46 PM, Jack Gallagher [email protected] wrote:

Currently, functions like match_term return substitutions represented as a list of pairs. Why don't all these functions use maps instead of lists?

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/HOL-Theorem-Prover/HOL/issues/336

konrad-slind avatar Apr 09 '16 04:04 konrad-slind

Probably not - needed to use them when writing match_goal and was curious why they worked that way. Substitution lists coming from that should mostly be short (though if people start writing tactics with it that get run 1000+ times in a loop a more cache friendly structure might make a difference)

GallagherCommaJack avatar Apr 12 '16 04:04 GallagherCommaJack