A queue already has push_front()/push_back() and pop_front()/pop_back() functions. Are you defining new functions?
These functions are atomic, in that a single operation will complete prior to another operation starting. This means that you can’t have two active calls at the same time.
You could potentially create race conditions where you may pop before you push and not get the expected results, but that would be due to poor coding styles.