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

Dyno: fix iterator type methods #26457

Open
wants to merge 20 commits into
base: main
Choose a base branch
from

Conversation

DanilaFe
Copy link
Contributor

@DanilaFe DanilaFe commented Jan 2, 2025

Closes https://github.com/Cray/chapel-private/issues/6923.

Depends on #26454, #26455 and #26456 because this causes more Domain methods to be resolved.

The diff without the dependencies is here: https://github.com/chapel-lang/chapel/pull/26457/files/68534a0dc75efb7a330635416960361102c3eb0e..e151853d4581dd669c2b0750be55de72f28ea2a5

The issue was in resolving code like this:

class C {
  var x: int;
  var y: string;

  iter type myIter() {
    yield 3;
    yield 5;
    yield 7;
    yield 11;
  }
}

for i in C.myIter() do
  writeln(i);

Previously, dyno incorrectly set isMethod to be false, which made the this formal for methods to be incorrectly set. This PR adjusts this behavior to correctly track method calls when resolving iterator overloads.

Testing

  • dyno tests

For the purposes of stopping the search etc.

Signed-off-by: Danila Fedorin <[email protected]>
Signed-off-by: Danila Fedorin <[email protected]>
Signed-off-by: Danila Fedorin <[email protected]>
Signed-off-by: Danila Fedorin <[email protected]>
Signed-off-by: Danila Fedorin <[email protected]>
Signed-off-by: Danila Fedorin <[email protected]>
…vararg' and 'fix-zip-unpacking' into fix-iterator-methods
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

Successfully merging this pull request may close these issues.

1 participant