If you directly use low-level locking primitives, no.  However, Rust provides many higher-level concurrency mechanisms that avoid the problem entirely.  And typically, if you had some complex data structure with multiple levels of locks and ordering requirements on those locks to prevent deadlock, you&#x27;d want to encapsulate that data structure with methods that handle those locking requirements internally.