-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Move Option<Box<_>> into ExtraInstructionAttributes. Previously, CircuitInstruction and PackedInstruction held the ExtraInstructionAttributes struct within an Option<Box<_>>. By putting the Option<Box<_>> inside ExtraInstructionAttributes, we can use the struct itself to manage its memory and provide access to the attributes behind a nicer interface. The size of ExtraInstructionAttributes should be the same size as the old Option<Box<ExtraInstructionAttributes>>, so this should not have memory implications. * Address review comments. - Use tuple struct. - Use 'Attributes' over 'Attrs'. - Add doc comment for internal 'ExtraAttributes' struct. - Add doc comments for methods. - Add setters for unit and duration. * Fix performance regression from unnecessary dict creation.
- Loading branch information
1 parent
4c88a71
commit c655acb
Showing
8 changed files
with
209 additions
and
221 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.