Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • Iris Iris
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 170
    • Issues 170
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 24
    • Merge requests 24
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Iris
  • IrisIris
  • Issues
  • #170
Closed
Open
Issue created Mar 08, 2018 by Joseph Tassarotti@jtassaroDeveloper

iFresh should reserve fresh names

Right now iFresh just generates a name that is fresh with respect to the current context, but doesn't ensure that the generated name will not be returned again by subsequent calls to iFresh. As a result, the following pattern fails:

    let H1 := iFresh in
    let H2 := eval vm_compute in (match H1 with
              | IAnon x => IAnon (1 + x)
              | INamed x => IAnon 1
              end) in
    let pat :=constr:(IList [cons (IIdent H1) (cons (IIdent H2) nil)]) in 
    iDestruct "H" as pat.

because iDestruct will also use iFresh and gets a name that conflicts with H1.

One solution would be to add a counter to the envs record which is incremented each time iFresh is called. This would actually also probably make iFresh more efficient anyway.

Assignee
Assign to
Time tracking