Skip to content
Permalink
Browse files

Make eqv on signatures test the returns. So, multi method stubs will …

…enforce return values. #2385
  • Loading branch information...
FCO committed Oct 21, 2018
1 parent f758f4d commit abba67b2281c57abf2e8a4933455a8cd3f5a26ab
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/core/Signature.pm6
@@ -146,6 +146,9 @@ multi sub infix:<eqv>(Signature:D \a, Signature:D \b) {
# different container type
return False unless a.WHAT =:= b.WHAT;

# different return
return False unless a.returns =:= b.returns;

# arity or count mismatch
return False if a.arity != b.arity || a.count != b.count;

0 comments on commit abba67b

Please sign in to comment.
You can’t perform that action at this time.