Sujet : Re: C23 thoughts and opinions
De : bc (at) *nospam* freeuk.com (bart)
Groupes : comp.lang.cDate : 01. Jun 2024, 11:09:25
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v3es0l$2nkse$1@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
User-Agent : Mozilla Thunderbird
On 01/06/2024 02:37, jak wrote:
bart ha scritto:
I can see that the first two can be subtracted to give the sizes of the data, which is 70 or 0x46. 0x46 is the last byte of the address of _size, so what's happening there? What's with the crap in bits 16-47?
>
I can extract the size using:
>
printf("%d\n", (unsigned short)&_binary_hello_c_size);
>
But something is not right. I've also asked what is the point of the -size symbol if you can just do -end - -start, but nobody has explained.
typedef unsigned char uchar;
extern uchar _binary_hello_c_size[];
long hello_c_size = _binary_hello_c_size - (uchar *)0;
What result for the size did you get when you ran this?
It seems people are just guessing what might be the right code and posting random fragments!