Final.java 363 Bytes
Newer Older
Bryce McKinlay committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
public final class Final
{
  public static void main(String args[])
    {
      Final f = null;
      try
        {
          f.doSomething();
        }
      catch (NullPointerException x)
        {
          System.out.println("NullPointerException - ok");
        }
    }

  void doSomething()
    {
      System.out.println("This should not happen");
    }
}