Enable test for exceptions
This commit is contained in:
parent
f66a1970b9
commit
173de1db30
20
test/Prompt/Exceptions.C
Normal file
20
test/Prompt/Exceptions.C
Normal file
@ -0,0 +1,20 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// CLING - the C++ LLVM-based InterpreterG :)
|
||||
//
|
||||
// This file is dual-licensed: you can choose to license it under the University
|
||||
// of Illinois Open Source License or the GNU Lesser General Public License. See
|
||||
// LICENSE.TXT for details.
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// RUN: cat %s | %cling 2>&1 | FileCheck %s
|
||||
extern "C" int printf(const char*,...);
|
||||
|
||||
struct TheStruct {
|
||||
char m_Storage[100];
|
||||
};
|
||||
|
||||
// CHECK: About to throw "ABC"
|
||||
printf("About to throw \"ABC\"\n");
|
||||
TheStruct getStructButThrows() { throw "ABC!"; }
|
||||
// CHECK: Exception occurred. Recovering...
|
||||
getStructButThrows()
|
@ -1,6 +0,0 @@
|
||||
struct TheStruct {
|
||||
char m_Storage[100];
|
||||
};
|
||||
|
||||
TheStruct getStructButThrows() { throw "ABC!"; }
|
||||
getStructButThrows()
|
Loading…
Reference in New Issue
Block a user