Skip to content

chore(hw): Reduce Memory boilerplate #5

@clabby

Description

@clabby

Overview

In the Memory trait, we have separate get/set functions for byte, halfword, word, and doubleword accesses. All of the implementations are the same, barring the field size.

We should look to reduce this boilerplate a bit, and create a single get/set function for all access widths. num-traits would likely be the best way to do this, but unfortunately, it does not have const handles for a type's bit length, min value, or max value.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions