Quantcast
Channel: Intel® C++ Compiler
Viewing all articles
Browse latest Browse all 1616

SIGABRT when throwing exception from code compiled with clang++ in subproject of Intel C++ project in OSX XCode 5 32 bit

$
0
0

I have a very simple 32 bit Xcode project setup running under OSX 10.9.5, Xcode 5.2

Main project - compiled by Intel C++ calling constructor of a class in a subproject. Subproject is a static library, compiled by llvm clang++.

In my main project (Intel C++) I have:

main.cpp:

#include "test.h"

int main(int argc, const char * argv[])

{

    test t;

    return 0;

}

In my subproject (LLVM Clang++) I have:

test.h:

class test {

public:

    test();

};

test.cpp:

#include "test.h"

test::test()

{

    try {

        throw 1;

    } catch (...) { 

    }

}

Exception, thrown in test::test() is not caught, causing abnormal termination. 

When I change compiler of my main project to LLVM Clang++, the exception is caught as expected.

I've attached my test project.

AdjuntoTamaño
Descargartest_1.zip752.41 KB

Viewing all articles
Browse latest Browse all 1616

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>