> I think you drilled too much into the "mutex" and "locked" aspects, rather than thinking of the immovable and post initialization.

 

But it std::mutex is immovable for a reason ,and there’s only 1 way to initialize it. And the way it works defeats the purpose of this discussion.

 

 

> I mistakenly cut part of my response. The "getMutexTheOtherTeamToldMeToUse()" could be an application wide function that your project needs to use for logging/tracking.
> With that, you cannot forget to call the post-initialization. It's done for you.

 

But as I have explained there cannot be a “getMutexTheOtherTeamToldMeToUse()” because it is a std::mutex and it must be initialized at the address provided by the caller.

 

 

> There are even other types that *are* movable but moving is not cheap.

 

And I understand that. But as I have said std::mutex is not a good example.

Give me a better example and then I will tell you if it makes sense or not, and then let’s see if the reasons you want for doing this makes sense. For std::mutex it does not!