blob: b4860b85b60ce218e9ec61a7b9dd227c11f146a6 (
plain) (
tree)
|
|
namespace Ryujinx.Common
{
public static class SharedPools
{
private static class DefaultPool<T>
where T : class, new()
{
public static readonly ObjectPool<T> Instance = new ObjectPool<T>(() => new T(), 20);
}
public static ObjectPool<T> Default<T>()
where T : class, new()
{
return DefaultPool<T>.Instance;
}
}
}
|