For questions about using or overloading the C++ ->* (pointer-to-member) operator.
Questions tagged [operator-arrow-star]
4 questions
93
votes
7 answers
What are the pointer-to-member operators ->* and .* in C++?
Yes, I've seen this question and this FAQ, but I still don't understand what ->* and .* mean in C++.
Those pages provide information about the operators (such as overloading), but don't seem to explain well what they are.
What are ->* and .* in…

user541686
- 205,094
- 128
- 528
- 886
56
votes
3 answers
Strange "->* []" expression in C++ source code of cpp.react library
Here is a C++ snippet that I found in the documentation of the cpp.react library:
auto in = D::MakeVar(0);
auto op1 = in ->* [] (int in)
{
int result = in /* Costly operation #1 */;
return result;
};
I have never seen the ->* [] notation.…

Philipp Claßen
- 41,306
- 31
- 146
- 239
22
votes
3 answers
What is ->* operator in C++?
C++ continues to surprise me.
Today i found out about the ->* operator. It is overloadable but i have no idea how to invoke it. I manage to overload it in my class but i have no clue how to call it.
struct B { int a; };
struct A
{
typedef int…
user34537
7
votes
3 answers
What is the correct term for ->,->* and .* operators?
Wikipedia refers to them as:
-> Member b of object pointed to by a
->* Member pointed to by b of object pointed to by a
.* Member pointed to by b of object a
But I need to refer to them without using "a" and "b". Do they have any names?

Pubby
- 51,882
- 13
- 139
- 180