class X::TypeCheck::Binding

Error due to a failed type check during binding
class X::TypeCheck::Binding is X::TypeCheck { }

Thrown when the type check of a binding operation fails.

For example:

my Int $x := "foo";
    CATCH { default { put .^name, ': ', .Str } };
    # OUTPUT: «X::TypeCheck::Binding: Type check failed in binding; expected Int but got Str ("foo")␀»

Note that the compiler is free to detect obvious errors at compile time, and complain with a different error at compile time.

The Camelia image is copyright 2009 by Larry Wall. "Raku" is a trademark of the Yet Another Society. All rights reserved.

Built with Podlite β€” the markup and publishing tools behind this site.