Sujet : Re: Can someone please verify the execution trace of this?
De : chris.m.thomasson.1 (at) *nospam* gmail.com (Chris M. Thomasson)
Groupes : comp.lang.c comp.lang.c++Date : 20. May 2024, 21:48:06
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v2gcu7$5jfs$8@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
User-Agent : Mozilla Thunderbird
On 5/20/2024 1:36 PM, olcott wrote:
[...]
*IF YOU NEED TO RE0READ THIS 500 TIMES TO GET IT PLEASE DO*
*IF YOU NEED TO RE0READ THIS 500 TIMES TO GET IT PLEASE DO*
*IF YOU NEED TO RE0READ THIS 500 TIMES TO GET IT PLEASE DO*
[...]
Well, your C program needs H to be defined:
______________________
typedef int (*ptr)(); // ptr is pointer to int function
int H(ptr x, ptr y);
int D(ptr x)
{
int Halt_Status = H(x, x);
if (Halt_Status)
HERE: goto HERE;
return Halt_Status;
}
int main()
{
H(D,D);
return 0;
}
______________________
Just on an online C compiler:
/rbin/ld: /tmp/ccWEmrz1.o: in function `D':
rJgigMp7Qh.c:(.text+0x1b): undefined reference to `H'
/rbin/ld: /tmp/ccWEmrz1.o: in function `main':
rJgigMp7Qh.c:(.text+0x3f): undefined reference to `H'
ERROR!
collect2: error: ld returned 1 exit status
So, what you going on about?