There is no guarantee that garbage collection will take place, because there is no guarantee that the JVM supports garbage collection (I don’t think it is mentioned in JLS at all, of course, not in index ).
However, I think this belief that “this is not guaranteed” is a little inappropriate. From Sun API docs :
, Java , .
, , , , , JVM GC, . , JVM , , , - , , .
, . JVM , .