From f755bf73bfd1d626670caa27ded5876784b915c0 Mon Sep 17 00:00:00 2001
From: William S Fulton
+Non-conventional type declarations. For example, SWIG does not support declarations such as the following (even though this is legal C): -
+
/* Non-conventional placement of storage specifier (extern) */ @@ -348,7 +350,6 @@ void bar(Spam (Grok)(Doh));
In practice, few (if any) C programmers actually write code like @@ -357,27 +358,32 @@ if you're feeling particularly obfuscated, you can certainly break SWIG (althoug
+Running SWIG on C++ source files (the code in a .C, .cpp or .cxx file) is not recommended. +The usual approach is to feed SWIG header files for parsing C++ definitions and declarations. +The main reason is if SWIG parses a scoped definition or declaration (as is normal for C++ source files), +it is ignored, unless a declaration for the symbol was parsed earlier. +For example +
-/* Not supported by SWIG */
+/* bar not wrapped unless foo has been defined and
+ the declaration of bar within foo has already been parsed */
int foo::bar(int) {
... whatever ...
}
+Certain advanced features of C++ such as nested classes +are not yet fully supported. Please see the C++ Nested classes section for more information. +