Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • F fix
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • POTTIER Francois
  • fix
  • Merge requests
  • !3

Indexing: Empty vector has empty domain

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged BOUR Frederic requested to merge fbour/fix:master into master Feb 07, 2022
  • Overview 4
  • Commits 1
  • Changes 1

This fixes a minor soundness/safety issue in the Indexing module.

The domain of vectors is reflected at the type-level to guarantee, at compile-time, that accesses are safe. A (n, a) vector has a value of type a for each value in the set n cardinal.

However, the empty vector is given a type polymorphic in its domain: Vector.empty : (_, _) vector. Thus, the empty vector can be used with any domain, which breaks the guarantee above.

Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: master