namespace Caliburn.MemoryManagement { // Provides a weak reference to a null target object, which, unlike // other weak references, is always considered to be alive. This // facilitates handling null dictionary values, which are perfectly // legal. internal class WeakNullReference : WeakReference where T : class { public static readonly WeakNullReference Singleton = new WeakNullReference(); private WeakNullReference() : base(null) {} public override bool IsAlive { get { return true; } } } }