Skip to content

In tstate::auxiliary::constraint, find a way to "freeze" the descs field #2539

@catamorphism

Description

@catamorphism

This is a supreme yak-shave, but the type tstate::auxiliary::constraint has a mutable vector (dvec) field called descs, but it only needs to be mutable during the collect_locals part of typestate. Ideally collect_locals would use this type internally, then return a different type that has an immutable vector field. But I'm not sure if there's a good way to turn a dvec into an immutable vector.

Contingent on typestate not getting removed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-cleanupCategory: PRs that clean code up or issues documenting cleanup.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions