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

should getindex(x::Number,1) return an error? #35988

Closed
gszep opened this issue May 22, 2020 · 1 comment
Closed

should getindex(x::Number,1) return an error? #35988

gszep opened this issue May 22, 2020 · 1 comment

Comments

@gszep
Copy link

gszep commented May 22, 2020

the follow is currently allowed in Julia 1.3.1

x = 42 # any typeof(x):<Number
x[1] # returns 42

but should it be?

@KristofferC
Copy link
Member

See the discussion in #7903

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

No branches or pull requests

2 participants