Invoking Function Operator via Thread Creates a Copy

I'm playing around with std::thread and using it to invoke a class instance's function operator. I have noticed that you can invoke it from more than one thread but it creates a copy of the instance via the class's copy constructor.

I would like to have more than one thread invoking the function operator from the same instance.
I'll answer my own question. You construct the thread using std::ref.

thread worker(ref(some_instance));
Topic archived. No new replies allowed.