<div dir="auto"><div dir="auto">Hello everyone,</div><div dir="auto"><br></div>std::scoped_lock taking in just a variadic mutexes is restrictive. <div dir="auto">In one such scenario where there are jobs that are scheduled. These jobs has their own set of tasks to achieve. These task can work on a set of configurable inputs and outputs. The outputs of one of the task can be an input of another task under a different job that is scheduled. Since these are configurable, the mutexes creation is done during the process init and job scheduling. Hence there is no way to use scoped_lock which is an excellent addition to lock all or nothing mutexes that avoids deadlock. </div><div dir="auto">How about an RAII for scoped_lock which takes a std container of mutexes (or unique ptrs of mutexes). ? Is this a valid proposal? Am I missing something that is already there and easy to use like scoped lock?</div><div dir="auto"><br></div><div dir="auto">Regards</div><div dir="auto">Bharath</div></div>

