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

primed function (partial applied), fails type check and mentions being "CURRIED" not partially applied or "primed" #3705

Closed
p6rt opened this issue Feb 26, 2015 · 7 comments

Comments

@p6rt
Copy link

p6rt commented Feb 26, 2015

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

Searchable as RT123938$

@p6rt
Copy link
Author

p6rt commented Feb 26, 2015

From the.ashleydev+rt.cpan.org@gmail.com

(11​:01) < TimToady> m​: sub same'proto(​::T, T $a, T $b) { $a.WHAT === $b.WHAT }; my &infix​:<same-in-Int> = &same'proto.assuming(Int); say 42 same-in-Int "42"
(11​:01) <+camelia> rakudo-moar 3607d7​: OUTPUT«Type check failed in binding $b; expected 'Int' but got 'Str'␤ in sub same'proto at /tmp/hHGw6Gs9QV​:1␤ in sub CURRIED at src/gen/m-CORE.setting​:4136␤ in block <unit> at /tmp/hHGw6Gs9QV​:1␤␤»

see​: http://irclog.perlgeek.de/perl6/2015-02-26#i_10185459

@p6rt
Copy link
Author

p6rt commented Feb 26, 2015

From the.ashleydev+rt.cpan.org@gmail.com

Note the typecheck is is correct -- it's just the error message mentioning curry that's incorrect.

@p6rt
Copy link
Author

p6rt commented Aug 9, 2015

From @skids

The current error message is now​:

$ perl6 -e 'sub same'"'"'proto(​::T, T $a, T $b) { $a.WHAT === $b.WHAT }; my &infix​:<same-in-Int> = &same'"'"'proto.assuming(Int); say 42 same-in-Int "42"'
Type check failed in binding $b; expected 'Int' but got 'Str'
  in sub same'proto at -e​:1
  in sub __PRIMED_ANON at EVAL_2​:4
  in sub __PRIMED_ANON at EVAL_2​:1
  in block <unit> at -e​:1

I believe that will be satisfactory?

I have added a test to perl6 S06-currying/misc.t.

So this ticket may now be closeable, I think.

@p6rt
Copy link
Author

p6rt commented Aug 9, 2015

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

@p6rt
Copy link
Author

p6rt commented Aug 16, 2015

From @usev6

Reading through the ticket and the mentioned IRC logs, the current error message looks good to me. I'm closing this ticket as 'resolved'.

Please reopen if the backtrace isn't awesome enough.

1 similar comment
@p6rt
Copy link
Author

p6rt commented Aug 16, 2015

From @usev6

Reading through the ticket and the mentioned IRC logs, the current error message looks good to me. I'm closing this ticket as 'resolved'.

Please reopen if the backtrace isn't awesome enough.

@p6rt p6rt closed this as completed Aug 16, 2015
@p6rt
Copy link
Author

p6rt commented Aug 16, 2015

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

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

No branches or pull requests

1 participant