# Copyright (c) 2012 Google Inc. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

{
 'targets': [
    {
      'target_name': 'test_eh_off',
      'product_name': 'test_eh_off',
      'type': 'executable',
      'msvs_settings': {
        'VCCLCompilerTool': {
          'ExceptionHandling': '0',
          'WarnAsError': 'true'
        }
      },
      'sources': [
        'exception-handling-on.cc'
      ]
    },
    {
      'target_name': 'test_eh_s',
      'product_name': 'test_eh_s',
      'type': 'executable',
      'msvs_settings': {
        'VCCLCompilerTool': {
          'ExceptionHandling': '1',
          'WarnAsError': 'true'
        }
      },
      'sources': [
        'exception-handling-on.cc'
      ]
    },
    {
      'target_name': 'test_eh_a',
      'product_name': 'test_eh_a',
      'type': 'executable',
      'msvs_settings': {
        'VCCLCompilerTool': {
          'ExceptionHandling': '2',
          'WarnAsError': 'true'
        }
      },
      'sources': [
        'exception-handling-on.cc'
      ]
    },
  ]
}

@@ -166,22 +166,161 @@
 ets': %5B%0A
+    # Optimization disabled so that the exception-causing code is not removed%0A    # (divide by zero was getting optimized away in VS2010).%0A
     %7B%0A
-
       't
@@ -526,32 +526,64 @@
 AsError': 'true'
+,%0A          'Optimization': '0',
 %0A        %7D%0A     
@@ -872,32 +872,64 @@
 AsError': 'true'
+,%0A          'Optimization': '0',
 %0A        %7D%0A     
@@ -1195,16 +1195,16 @@
 ': '2',%0A
-
         
@@ -1226,16 +1226,48 @@
 : 'true'
+,%0A          'Optimization': '0',
 %0A       

Fix exception handling test on vs2010