Record of some of the computer tech I deal with so that it's documented at least somewhere.

Tuesday 25 December 2007

Limbo Exceptions

I keep forgetting the syntax so I'm putting it here because it's not in the manuals, it's in addendum.pdf but that's no use in Inferno!
{
if(might_raise()) {
raise "True";
} else {
raise "False";
}
} exception e {
"True" => sys->print("True was raised\n");
"F*" => sys->print("False was raised (or anything starting F)\n");
"*" => sys->print("Something else was raised\n");
}

No comments: