MOO-cows Mailing List Archive

[Prev][Next][Index][Thread]

raise()



One problem that I experience those days is catching errors, analyse the
value/message and raise() it again if I can't do anything with the value...
it works nicely, except the traceback that result is not as informative :(

I was wondering if we could have a reraise() bf (or reraise; statement)
that would continue the raising (and error catching) process as if the
except clause containing the bf call/statement has not caight it?

Example

...
try
  foo:do_stuff(e_perm_trigger);
except error (E_PERM)
  {code, msg, value, tb} = error;
  if (value == e_perm_trigger)
    player:tell(msg);
    return;
  else
    "usually I raise(code, msg, value) but lose the tb info :(";
    reraise;
  endif
endtry


-- Richard




Follow-Ups:

Home | Subject Index | Thread Index