You shouldn't make explicit calls to main(). You can use exception handling for breaking code blocks, however it really depends on the actual problem.