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

Indexing rework for 0.2 #19

Open
brainandforce opened this issue Aug 8, 2024 · 1 comment
Open

Indexing rework for 0.2 #19

brainandforce opened this issue Aug 8, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@brainandforce
Copy link
Owner

Because we currently disallow bare integer indices for AbstractCliffordNumber instances, we could rework the indexing scheme to allow for integer indices if the inputs to getindex are passed through to BitIndex:

getindex(x::AbstractCliffordNumber, i::Integer...) = getindex(x, BitIndex(x, i...))

This is a relatively naive definition; we may want to perform checking so that a BitIndex of a grade constrained to be zero by the type of x automatically returns zero without performing any construction.

@brainandforce brainandforce added the enhancement New feature or request label Aug 8, 2024
@brainandforce
Copy link
Owner Author

This actually may not be a breaking change, and can go into the 0.1 series.

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

No branches or pull requests

1 participant