垃圾收集器一题!??,,
public class X
{
public object m() {
object o =new float (3.14F);
object [] oa =new object[1];
oa[0]=o;
o=null;
oa[0]=null;
return o;
}
}
when is the float object ,created in line 4,eligible for garbage collection?
a.just after line 6
b.just after line 7
c.just after line 8
d.just after line 9(that is,as the method returns)
我认为选d,但是我也不太明白,大家认为选那个》?
return o;//这行在这里起什么作用????