shithub: scc

ref: 3e74db0e8da377cee03ec3c7825ddad168045055
dir: /tests/execute/0092-fptr.c/

View raw version

int
zero()
{
	return 0;
}

struct S
{
	int (*zerofunc)();
} s = { &zero };

struct S *
anon()
{
	return &s;
}

typedef struct S * (*fty)();

fty
go()
{
	return &anon;
}

int
main()
{
	return go()()->zerofunc();
}