1

Topic: To appropriate a variable value void functions

At me today the strange question because I, actually, not so understand, whether is it at me, or me is simple . Business was so. I sit, I am picked with With ++, I write an educational aaplet. Wrote function, like the such

void read (unsigned char &value)

And further was, as it seems to me, a call

val = read (val)

It seems - because I then thought, well a hogwash any, whether it is not enough, in a C ++ value void can is possible for function to something to appropriate. Deleted this code, and, unfortunately, did not save. And then decided to understand, but I can not repeat.
In this connection a question - in a C ++ it is valid so it is possible to make, can be in any specific conditions? Or all it seemed to me?

2

Re: To appropriate a variable value void functions

Seemed.

3

Re: To appropriate a variable value void functions

Rusty nail;
It is impossible to appropriate, because it is impossible to declare a variable or argument of type void.
But if causing function too returns void that it is possible to write so:

return read (val);

4

Re: To appropriate a variable value void functions

Here thanks, calmed