fork download
  1. public class ExceptionHandling {
  2. public static void myMethod(Integer i) {
  3. try {
  4. Integer a = i;
  5. Integer b = a * 5;
  6. } catch (Exception e) {
  7. System.debug('I catch the Exception');
  8. }
  9. }
  10. }
Success #stdin #stdout #stderr 0.01s 8940KB
stdin
I=0
stdout
Object: UndefinedObject error: did not understand #ExceptionHandling
MessageNotUnderstood(Exception)>>signal (ExcHandling.st:254)
UndefinedObject class(Object)>>doesNotUnderstand: #ExceptionHandling (SysExcept.st:1448)
UndefinedObject>>executeStatements (prog:1)
stderr
./prog:2: parse error, expected '}'