title: How to enable Exception Handling on XCode 3.2.3?
body: <p>How to enable exceptions in XCode - 3.2.3. Is there any flag like I should enable for the compiler for exception handling? Tried googling but didn't find enough information on XCode with <code>C++</code> !</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;exception&gt;
  
  int main()
  {
      try
      {
          int i=5,j=0;
          int res = i/j;
      }
      catch (const std::exception&amp; exe) 
      {
          std::cerr&lt;&lt; exe.what();
      }
      catch (...)
      {
          std::cout&lt;&lt; "\n Default Exception Handler \n";
      }
  
      return 0;
  }
  </code></pre>
  
  <p>Output:</p>
  
  <blockquote>
    <p>Loading program into debugger…<br>
    Program loaded.<br>
    run<br>
    [Switching to process 1332]<br>
    Running…<br>
    Program received signal:  “EXC_ARITHMETIC”.<br>
    sharedlibrary apply-load-rules all<br>
    kill<br>
    Current language:  auto; currently c++<br>
    quit<br>
    The Debugger has exited with status 0.(gdb) </p>
  </blockquote>
  
  <p>Edit :Though the reason seems to be different, to anyone, this figure might be helpful in future.<img src="https://i.stack.imgur.com/SB0bE.png" alt="">  </p>