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

Index and IndexMut trait. #429

Open
otrho opened this issue Nov 30, 2021 · 0 comments
Open

Index and IndexMut trait. #429

otrho opened this issue Nov 30, 2021 · 0 comments
Labels
compiler General compiler. Should eventually become more specific as the issue is triaged enhancement New feature or request language feature Core language features visible to end users lib: std Standard library P: low

Comments

@otrho
Copy link
Contributor

otrho commented Nov 30, 2021

#424 introduced static arrays and indexing them though indexing other types we need the Index and possibly IndexMut traits. These would mimic the Rust equivalents.

The existing code tries to call self.index(arg) by in fact just calling std::ops::index(self, arg) which may itself be a bit wrong... I'm not sure how it should work mechanically.

@otrho otrho added compiler General compiler. Should eventually become more specific as the issue is triaged lib: std Standard library labels Nov 30, 2021
@otrho otrho mentioned this issue Nov 30, 2021
@otrho otrho added the enhancement New feature or request label Nov 30, 2021
@mohammadfawaz mohammadfawaz added the language feature Core language features visible to end users label Mar 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler General compiler. Should eventually become more specific as the issue is triaged enhancement New feature or request language feature Core language features visible to end users lib: std Standard library P: low
Projects
Status: Todo
Development

No branches or pull requests

2 participants