I honestly searched and tried to implement try - catch mechanism in C++, but I failed: I don't have enough experience yet. In Android there is a convenient way to catch general exceptions, whether it's a division by zero or an array out-of-bounds, like
int res;
int a=1;
int b=0;
try{res = a/b;}
catch(Exception e)
{
int stop=1;
};
Works fine, program does not crash.
Could you please tell me how to make an universal exceptions interceptor in C++, if possible.