3
I would like to ask a question that is best left with an example:
I have the following piece of code in C:
char texto[]="String";
int (*ret)() = (int(*)())texto;
In this section above, I saw that a pointer is declared to function called Ret, but I did not understand what is assigned to it.
Would it be a casting? Like, he gets the address of texto[]
and converts it to a function?
I don’t get it, it sounds like you’re asking someone specifically.
– user28595
Sorry, I had never posted here kkkkkkk
– user39224
@user39224 as Bacco said: from a walk by Tuor, you will find out how the site works won medals and managed to answer more questions still!
– Junior Moreira
@user39224 I edited your question to be more suitable to the format of the site, but it is recommended to read the documentation here: [Tour] and [Ask] so that in the next (or even if you want to edit this question) you can better elaborate the post.
– Bacco
Thank you, I will read yes.
– user39224
@user39224 besides reading the topics mentioned, register and come to be part of the community, we have much to learn and you will not miss with it :)
– Junior Moreira
Can you give a functional example of this? Can you post code with more context? Where did you find this? Have a look at http://answall.com/help/mcve
– Maniero