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

MMD doesn't take methods of parent class into account #720

Closed
p6rt opened this issue Feb 24, 2009 · 4 comments
Closed

MMD doesn't take methods of parent class into account #720

p6rt opened this issue Feb 24, 2009 · 4 comments

Comments

@p6rt
Copy link

p6rt commented Feb 24, 2009

Migrated from rt.perl.org#63442 (status was 'resolved')

Searchable as RT63442$

@p6rt
Copy link
Author

p6rt commented Feb 24, 2009

From @moritz

Rakudo 93bde8cd8f7478a34a76c434b517388a28801c3b​:

class Foo {
  multi method a($d) {
  say "Any-method in Foo";
  }
}
class Bar is Foo {
  multi method a(Int $d) {
  say "Int-method in Bar";
  }
}

Bar.new.a("not an Int");

# vim​: ft=perl6

Output​:
No applicable candidates found to dispatch to for 'a'
current instr.​: 'parrot;P6metaclass;dispatch' pc 109
(src/classes/ClassHOW.pir​:85)

This will be a test in t/spec/S12-methods/multi.t in a few minutes.

Cheers,
Moritz

--
Moritz Lenz
http://perlgeek.de/ | http://perl-6.de/ | http://sudokugarden.de/

@p6rt
Copy link
Author

p6rt commented Feb 25, 2009

From @jnthn

On Tue Feb 24 09​:33​:18 2009, mlenz@​physik.uni-wuerzburg.de wrote​:

class Foo {
multi method a($d) {
say "Any-method in Foo";
}
}
class Bar is Foo {
multi method a(Int $d) {
say "Int-method in Bar";
}
}

Bar.new.a("not an Int");

# vim​: ft=perl6

Output​:
No applicable candidates found to dispatch to for 'a'
current instr.​: 'parrot;P6metaclass;dispatch' pc 109
(src/classes/ClassHOW.pir​:85)

Ah yes, I've been needing to fix this up for a while. Finally it's done
in git f43750a.

This will be a test in t/spec/S12-methods/multi.t in a few minutes.

Corrected and unfudged.

Thanks,

Jonathan

@p6rt
Copy link
Author

p6rt commented Feb 25, 2009

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Feb 25, 2009

@jnthn - Status changed from 'open' to 'resolved'

@p6rt p6rt closed this as completed Feb 25, 2009
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

1 participant