handle
handle is a 32-bit integer smart pointer reference to an object.
It is the primitive type from which all other types defined in common.j extend from. The actual type is largely unused in Jass - common.j does not contain a single native that takes or returns a handle. The handle type can, however, be useful in cases where polymorphism is needed, the most notable example being H2I.
It is known that Jass implements reference counting so that handles of destroyed objects can be reused later. This is why all local handle variables (or local variables of any type that extends from handle) should be set to null before the end of a function.
local timer t1 = CreateTimer() // creates a handle and sets reference count to 1
local timer t2 = t1 // another variable now points to the same timer - reference count becomes 2
call DestroyTimer(t1) // the timer is destroyed, but it's handle still has two references
set t1 = null // reference count is now 1
set t2 = null // reference count is now 0 - the handle is recycled