Uploaded image for project: 'Qbs ("Cubes")'
  1. Qbs ("Cubes")
  2. QBS-387

Implement a cpp.exceptionHandling property to control availability of exception handling

    XMLWordPrintable

Details

    • Task
    • Resolution: Done
    • P3: Somewhat important
    • 1.5.0
    • None
    • General
    • None
    • a235900a7368fd2edf269454016c7577cb674323

    Description

      As discussed on the mailing list.

      Module: cpp
      Property name: enableExceptions
      Property type: bool
      Default value: undefined

      • undefined - do nothing (exceptionHandlingModel also has no effect)
      • true - see exceptionHandlingModel for what happens
      • false - -fno-exceptions and -fno-objc-exceptions for GCC-family compilers, /EH- for MSVC-family compilers

      Module: cpp
      Property name: exceptionHandlingModel
      Property type: string
      Default value: "default"
      Allowed values:

      • MSVC:
        • "default" = /EHsc
        • "seh" = /EHa
        • "externc" = /EHs
      • GCC/MinGW:
        • "default" = -fexceptions, -fobjc-exceptions, -fobjc-arc-exceptions
      • MinGW:
        • "sjlj"
        • "seh"
        • "dwarf2" (or just "dwarf"?)

      Toolchain setup should set the value of exceptionHandlingModel.

      Visual Studio 2012's property pages option "Enable C++ Exceptions" gives the following choices:

      • Yes with SEH exceptions (/EHa)
      • Yes (/EHsc)
      • Yes with Extern C functions (/EHs)
      • No
      • <inherit from parent or project defaults>

      The documentation states "If /EH is not specified (i.e. "No" in VS), the compiler catches structured exceptions and C++ exceptions, but does not destroy C++ objects that go out of scope as a result of an exception."

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              jakepetroules Jake Petroules (DO NOT ASSIGN ISSUES)
              jakepetroules Jake Petroules (DO NOT ASSIGN ISSUES)
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes