Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow negative indices on Logic and LogicValue to relative to the end #99

Closed
mkorbel1 opened this issue Mar 29, 2022 · 1 comment · Fixed by #155
Closed

Allow negative indices on Logic and LogicValue to relative to the end #99

mkorbel1 opened this issue Mar 29, 2022 · 1 comment · Fixed by #155
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@mkorbel1
Copy link
Contributor

Motivation

Python allows you to access the end of a list using negative numbers, which is a nifty feature.

Desired solution

Functions like operator [], getRange, and slice should handle negative numbers, treating it as from the end of the value/signal. -1 is the last element, etc.

Alternatives considered

SystemVerilog does not support this.

@mkorbel1 mkorbel1 added enhancement New feature or request good first issue Good for newcomers labels Mar 29, 2022
@RPG-coder-intc
Copy link
Contributor

Hey Max, I will be working on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants