public static void Main()
var container = new Container();
x.For<SingletonConcreteType>().Singleton();
var instance1 = container.GetInstance<SingletonConcreteType>();
var instance2 = container.GetInstance<SingletonConcreteType>();
Console.WriteLine(instance1 == instance2);
Console.WriteLine(instance1.Id == instance2.Id);
var instance3 = container.GetInstance<ConcreteType>();
var instance4 = container.GetInstance<ConcreteType>();
Console.WriteLine(instance3.Id == instance4.Id);
public class SingletonConcreteType
public Guid Id = Guid.NewGuid();
public class ConcreteType
public Guid Id = Guid.NewGuid();