if (st.wanted_by.size()) {
auto front = st.wanted_by.front();
if (front == releaser_thread.get_id()) {
st.state = lock_state::locked;
st.held_by = releaser_thread.get_id();
st.wanted_by.pop_front();
if (st.wanted_by.size()) {
auto front = st.wanted_by.front();
if (front == releaser_thread.get_id()) {
st.state = lock_state::locked;
st.held_by = releaser_thread.get_id();
st.wanted_by.pop_front();