Skip to content

Implementer guidance: enum vs. heapless vec vs. size-and-length #85

Description

@chrysn

At some point in time we'll probably want to come up with a style guide that helps implementers decide whether the preferred way to do this is to have an enum with algorithms, this, or a heapless Vec -- and which of those are preferred for which type and why.

For the time being, we probably goes with what is easiest at that moment, and collect experience.

This is the place to do that. Considerations so far:

  • Unlike slices and vec, algorithms have a niche.
  • heapless might deduplicate nicely (but didn't test that, let's not take my word for it)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions