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

nth_methtable:variable n may be 0, we will get the index value of tuple as -1 #47625

Closed
awfeequdng opened this issue Nov 18, 2022 · 1 comment · Fixed by #47666
Closed

nth_methtable:variable n may be 0, we will get the index value of tuple as -1 #47625

awfeequdng opened this issue Nov 18, 2022 · 1 comment · Fixed by #47666
Labels
bug Indicates an unexpected problem or unintended behavior types and dispatch Types, subtyping and method dispatch

Comments

@awfeequdng
Copy link
Contributor

image

in latest master method.c, in function nth_methtable, variable n may be 0, we will get the index value of tuple as -1

@vtjnash vtjnash reopened this Nov 18, 2022
@brenhinkeller brenhinkeller added types and dispatch Types, subtyping and method dispatch bug Indicates an unexpected problem or unintended behavior labels Nov 19, 2022
apaz-cli added a commit to apaz-cli/julia that referenced this issue Nov 22, 2022
vtjnash pushed a commit that referenced this issue Nov 28, 2022
@vtjnash
Copy link
Sponsor Member

vtjnash commented Nov 28, 2022

Looking closer, I realized that jl_is_tuple_type(a) implies a->name == jl_tuple_typename and jl_tuple_typename->mt != NULL, so this was not truly ever able to be reached. But better to be clear about that intent in the code (#47666).

KristofferC pushed a commit that referenced this issue Dec 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior types and dispatch Types, subtyping and method dispatch
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants