Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hooking word into lia #56

Open
JasonGross opened this issue Jan 26, 2022 · 1 comment
Open

hooking word into lia #56

JasonGross opened this issue Jan 26, 2022 · 1 comment

Comments

@JasonGross
Copy link
Collaborator

Should https://github.com/mit-plv/bedrock2/blob/master/bedrock2/src/bedrock2/ZnWords.v be adapted to hook into the zify mechanism a la https://github.com/coq/coq/blob/master/theories/micromega/ZifyUint63.v and be integrated into coqutil?

@JasonGross JasonGross changed the title hooking word into lia hooking word into lia Jan 26, 2022
@samuelgruetter
Copy link
Contributor

Migrating ZnWords to coqutil would be ok with me.

Since ZnWords is supposed to work for every word n if n is a concrete constant, we would need parameterized zify typeclass instances, and the last time I tried to do that (not for ZnWords, but for LittleEndian), Frédéric Besson said

Don't expect zify to work with parameterized instances. Some error checking is missing but the error message should be something like "Dependent types are not allowed".
This is a strong restriction of the implementation that is hardwired very deep. Sorry.

Maaaybe we could duplicate the Add Zify ... commands for each word size of interest, but what if the word instance is a section variable? Use Load? Not sure if that's worth the trouble at the moment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants