Class having object of itself

In below code a class is having object of itself. Object of own type is created before class definition completes (before endclass.)
This is working. Compiler do not give any error. Can anyone explain me how this works?

class test;
  test self;
  function create_me();
    self = new();
    self.display("self");
  endfunction
  function display(string s = "this");
    $display("from function display %s",s);
  endfunction
endclass

module test_module();
  test test_ob;
  initial
    begin
      test_ob = new();
      test_ob.create_me();
      test_ob.display();
    end 
endmodule

Output :
from function display self
from function display this

In reply to Jinam Shah:

Hi Jinam,

If you call test_ob.create_me(), it enters into it and it creates a self object and calls self.display(“self”). So now if you call test_ob.display() it calls directly display with the string “this”, nowhere self object comes into picture.

In reply to Jinam Shah:
This class does not have an object of itself, it has a class variable
self
that will eventually hold a handle that can reference another class object of the same type. This is a very common data structures like a queue or tree used in many other programming languages. See Binary Trees in C++ - Cprogramming.com