This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Function with two or more entry point
- From: sztfg at yandex dot ru
- To: "gcc-help at gcc dot gnu dot org" <gcc-help at gcc dot gnu dot org>
- Date: Wed, 13 Mar 2013 04:30:31 +0400
- Subject: Re: Function with two or more entry point
- References: <250151363119434@web23h.yandex.ru>
The most similar (but without function):
#include <stdio.h>
int main ()
{
void *goto_after;
///////////////////////
if (0)
{
test_print1:
printf("print1\n");
test_print2:
printf("print2\n");
goto *goto_after;
}
///////////////////////
goto_after = &&label1; goto test_print1; label1:
goto_after = &&label2; goto test_print2; label2:
return 0;
}