(PUP-2314) Make assert_type handle lambda and user handling
This adds the ability to handle a Callable as the value, as well
as supporting a lambda that takes over the built in raising of
an error. This means that assert_type can be customized to fail
with special message, or to issue a warning and use a default.
assert_type(String, 1) |$expected, $actual| {
warning("a $actual is not a $expected") "Free Beer, is the default"
}