Make sure readonly goes before non readonly
MODIFY
WalletWasabi/Nito/AsyncEx/AsyncLock.cs
WalletWasabi/Nito/AsyncEx/AsyncLock.cs
@@ -49,24 +49,24 @@ namespace Nito.AsyncEx
public sealed class AsyncLock
{
/// <summary>
- /// Whether the lock is taken by a task.
+ /// The queue of TCSs that other tasks are awaiting to acquire the lock.
/// </summary>
- private bool _taken;
+ private readonly IAsyncWaitQueue<IDisposable> Queue;
/// <summary>
- /// The queue of TCSs that other tasks are awaiting to acquire the lock.
+ /// The object used for mutual exclusion.
/// </summary>
- private readonly IAsyncWaitQueue<IDisposable> Queue;
+ private readonly object Mutex;
/// <summary>
- /// The semi-unique identifier for this instance. This is 0 if the id has not yet been created.
+ /// Whether the lock is taken by a task.
/// </summary>
- private int _id;
+ private bool _taken;
/// <summary>
- /// The object used for mutual exclusion.
+ /// The semi-unique identifier for this instance. This is 0 if the id has not yet been created.
/// </summary>
- private readonly object Mutex;
+ private int _id;
/// <summary>
/// Creates a new async-compatible mutual exclusion lock.

Make sure readonly goes before non readonly