check if Main.main is defined