fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
  10. public void m1() throws IOException {
  11. m2();
  12. try {
  13. m2();
  14. } catch (IOException e) {
  15. System.out.println("m1 IOException");
  16. }
  17. }
  18.  
  19. public void m2() throws IOException {
  20. throw new IOException();
  21. }
  22.  
  23. public static void main (String[] args) throws java.lang.Exception
  24. {
  25. try {
  26. Ideone ide = new Ideone();
  27. ide.m1();
  28. } catch (IOException e) {
  29. System.out.println("main IOException");
  30. }
  31.  
  32. }
  33. }
Success #stdin #stdout 0.06s 380160KB
stdin
Standard input is empty
stdout
main IOException