I have a function prototype like
test(something &)
and i am doing
something *ss = new something();
Your function expects a reference to something
, and you are passing it a pointer to something
. You need to de-reference the pointer:
test(*ss);
That way the function takes a reference to the object pointed at by ss
. If you had a something
object, you could pass that directly to:
something sss;
test(sss); // test takes a reference to the sss object.