I have seen something in this form:
void function( A_struct &var ) {
var.field0 = 0;
// ...
}
Since there is & before var, I thought that var is a pointer. But in the body, instead of writing var->field0, var.field0 is written. So, my questions are:
Isn't
vara pointer?What is the difference between writing
A_struct &varandA_struct *varin function parameter?