new tests

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5161 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Dave Beazley 2003-09-26 19:56:45 +00:00
commit 6fb7cf7200
4 changed files with 56 additions and 0 deletions

View file

@ -46,7 +46,10 @@ DYNAMIC_LIB_PATH = $(RUNTIMEDIR):.
# Broken C++ test cases. (Can be run individually using make testcase.cpptest.)
CPP_TEST_BROKEN += \
array_typedef_memberin \
defvalue_constructor \
exception_order \
extern_throws \
namespace_union \
template_default_arg \
template_specialization_defarg \
template_specialization_enum \

View file

@ -0,0 +1,14 @@
%module defvalue_constructor
%inline %{
namespace Foo {
class Bar {};
class Baz {
public:
Baz(Bar b = Bar());
};
}
%}

View file

@ -0,0 +1,11 @@
%module extern_throws
%inline %{
#include <exception>
extern int get() throw(std::exception);
%}
%{
int get() throw(std::exception) { return 0; }
%}

View file

@ -0,0 +1,28 @@
%module namespace_union
%inline %{
namespace SpatialIndex
{
class Variant
{
public:
Variant() { };
int varType;
union
{
long lVal; // VT_LONG
short iVal; // VT_SHORT
float fltVal; // VT_FLOAT
double dblVal; // VT_DOUBLE
char cVal; // VT_CHAR
unsigned short uiVal; // VT_USHORT
unsigned long ulVal; // VT_ULONG
int intVal; // VT_INT
unsigned int uintVal; // VT_UINT
bool blVal; // VT_BOOL
char* pcVal; // VT_PCHAR
void* pvVal; // VT_PVOID
} val;
}; // Variant
}
%}