pointer and address?
-
What the differences in these code : Write(address, size, data) Write( address, size , &data) The function basically write data into a address, with size is the size of the data to be written . Thanks
it's really hard to say what will happen without knowing what Write is expecting for that 3rd parameter. but, in general: C++ pointers[^]
-
What the differences in these code : Write(address, size, data) Write( address, size , &data) The function basically write data into a address, with size is the size of the data to be written . Thanks
dec82 wrote:
Write(address, size, data) Write( address, size , &data)
What function defination says? or you have to consult the function writer... as it very difficult to predict, what actually your write function do.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
Never mind - my own stupidity is the source of every "problem" - Mixturecheers, Alok Gupta VC Forum Q&A :- I/IV Support CRY- Child Relief and You
-
What the differences in these code : Write(address, size, data) Write( address, size , &data) The function basically write data into a address, with size is the size of the data to be written . Thanks
Only one of the two is correct, unless data is declared as an array (i.e., for instance
char data[8];
).If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
[My articles]