C
Cybertof
Hello,
I need some help about a strange thing.
I have the following declaration :
public class CLockeEnv
{
private static CLockeEnv mlockeEnv;
public CLockeEnv()
{
}
public static CLockeEnv GetInstance()
{
if(mlockeEnv == null)
mlockeEnv = new CLockeEnv();
// Returns existing instance in all cases
return mlockeEnv;
}
}
How do you explain than in the 'Locals/Watch' window, i have an infinite
hierarchical tree like :
mLockeEnv
- System.Obkect
- mLockeEnv
- System.Object
- mLockeEnv
- SystemObject
- mLockeEnv
- System.Object
+ mLockeEnv
(etc...infinitely...)
What are all these 'mLockeEnv' ?....do they consume memory ?....i don't
think so as they are not referenced (apart of the first one....), but
why does not the view stop to the first inner level ?
Regards,
Christophe.
I need some help about a strange thing.
I have the following declaration :
public class CLockeEnv
{
private static CLockeEnv mlockeEnv;
public CLockeEnv()
{
}
public static CLockeEnv GetInstance()
{
if(mlockeEnv == null)
mlockeEnv = new CLockeEnv();
// Returns existing instance in all cases
return mlockeEnv;
}
}
How do you explain than in the 'Locals/Watch' window, i have an infinite
hierarchical tree like :
mLockeEnv
- System.Obkect
- mLockeEnv
- System.Object
- mLockeEnv
- SystemObject
- mLockeEnv
- System.Object
+ mLockeEnv
(etc...infinitely...)
What are all these 'mLockeEnv' ?....do they consume memory ?....i don't
think so as they are not referenced (apart of the first one....), but
why does not the view stop to the first inner level ?
Regards,
Christophe.