FWIW there are two layers to this ticket: failure on operators, and
faiures within where clauses.
The error is due to a failure during evaluation the where clause
and does not say '$x' for the same reason this does not:
$ perl6 -e 'my Int $x; my $f = $x > 0;'
Invocant requires an instance of typ
IMHO, the message is actually slightly worse. Now it's talking about an
invocant when there are no classes or methods involved!
-Scott
On Wed, Mar 11, 2015 at 1:26 PM, Christian Bartolomaeus via RT <
bugs-comm...@bugs6.perl.org> wrote:
> The error message has changed slightly and now states th
The error message has changed slightly and now states that "Invocant requires
an instance".
$ perl6 -e 'sub f(Int $x where $x > 0) { say "yup" }; my Int $a; f($a);'
Invocant requires an instance, but a type object was passed
in method Bridge at src/gen/m-CORE.setting:5578
in sub infix:<>> at
# New Ticket Created by "Jimmy Zhuo"
# Please include the string: [perl #118865]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org:443/rt3/Ticket/Display.html?id=118865 >
JimmyZ> r: sub f(Int $x where $x > 0) { say "yup"