Skip to content

Rewrite Vector using list and small inversions #170

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

andres-erbsen
Copy link
Collaborator

@andres-erbsen andres-erbsen commented Jun 11, 2025

Closes #54

This PR is WIP but illustrative enough to see the direction. The idea is to keep the same type but remove anything that looks archaic, aiming for easy portability from old vector rather than drop-in compatibility.

Compat strategy:

  • First release: Vector and Fin wrap Compat.Vector92 and Compat.Fin92 when compatible, incompatible interfaces are deprecated.
  • Second release: Vector and Fin are replaced with new files, Compat.Vector92 and Compat.Fin92 do Require Export.

WIP steps:

  • Do we want to rename the modules and types? (see below)
  • Should new Vector stay template polymorphic? (this would be unfortunate but may be necessary for compat)
  • Transitional wrapper defining current vector in terms of new vector
  • Last remaining (boring) proof wrappers
  • Added changelog.
  • Added / updated documentation.
  • Opened overlay pull requests.
    • elpi tests that rely on kernel path to Vector.t

The main consideration for potential renaming is that the following ought to be able to coexist (and be distinguishable):

  • (current) Vector
  • Fixpoint of pairs isomorphic to current vector
  • sig list isomorphic to current vector
  • heterogeneous vector (Inductive indexed by list of type)
  • heterogeneous vector (Fixpoint consuming list of type returning pairs
  • heterogeneous vector (Fixpoint consuming list of type returning primitive pairs
  • Vector of sigT, constrained to have the right types using sig (maybe this one is silly)
  • list of sigT constrained to have the right length and types

@andres-erbsen andres-erbsen changed the title Rewrite Vector using list, small inversions, and dependent induction Rewrite Vector using list and small inversions Jun 12, 2025
@andres-erbsen andres-erbsen force-pushed the refactor-vector branch 10 times, most recently from 99436e4 to 6d6d327 Compare June 14, 2025 23:51
@andres-erbsen andres-erbsen marked this pull request as ready for review June 15, 2025 00:02
@andres-erbsen andres-erbsen force-pushed the refactor-vector branch 3 times, most recently from 7b8e5f5 to e71b904 Compare June 15, 2025 14:13
@andres-erbsen andres-erbsen marked this pull request as draft June 15, 2025 19:38
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

Successfully merging this pull request may close these issues.

Vector library needs to replaced/deprecated.
1 participant