Daniel Berlin wrote:
Actually, even for non-POD types, it catches a lot of templatized
member functions that mainly depend on size (but they are still
container classes).
Just another ( maybe stupid :-) ) idea. What about "partial merge"?
static int x = 0;
void a()
{
printf( "aaa" );
x = x + 1;
return;
}
void b()
{
printf( "bbb" );
x = x + 1;
return;
}
In sample code functions a() and b() aren't identical, but
after push of first printf's argument they become identical.
So, setting JMP in b() into a()'s code should produce valid code.