-
Notifications
You must be signed in to change notification settings - Fork 65
Open
Description
I'm compiling the library in a project without JIT compilation.
On an older version everything was working fine but now I'm receiving an exception in DefaultTypePool.Creator.
private static readonly Func<T> Creator = Expression.Lambda<Func<T>>(Expression.New(typeof(T))).Compile();
public object Get()
{
lock (_pool)
{
if (_pool.Count > 0)
{
return _pool.Dequeue();
}
}
return Creator();
}
The Creator is compiling at runtime but without JIT compilation can't work.
Is the Creator needed?
Can't DefaultTypePool.Get() just return new T() ?
Metadata
Metadata
Assignees
Labels
No labels