This information is based on the SWIG-3.0.1 release.
SWIG currently generates wrapper code for twenty different target languages:
In addition to this, the parse tree can be exported as XML and Lisp s-expressions.
Experimental work is also available for a Pike module.
- Allegro CL
SWIG is capable of wrapping all of ISO C99. Features include:
- Handling of all ISO C datatypes.
- Global functions, global variables, and constants.
- Structures and unions.
- Arrays and multidimensional arrays.
- Pointers to functions.
- Variable length arguments.
SWIG provides wrapping support for ISO C++11.
- All C++ datatypes.
- Pointers to members.
- Inheritance and multiple inheritance.
- Overloaded functions and methods (using dynamic dispatch).
- Overloaded operators.
- Static members.
- Namespaces (including using declarations, aliases, nesting, etc.)
- Nested classes
- Member templates
- Template specialization and partial specialization.
- Smart pointers
- C++ library support for strings and the STL.
- The majority of the new C++11 standard features.
C++ users who rely on advanced template programming techniques
(e.g., template meta-programming) should also be aware that SWIG
currently requires manual instantiation of all template classes.
Therefore, if your application somehow involves the instantiation of 50000
template classes, your mileage might vary.
SWIG provides a full C preprocessor with the following features:
- Macro expansion.
- Automatic wrapping of #define statements as constants (when applicable).
- Support for C99 (variadic macro expansion).
SWIG provides control over most aspects of wrapper generation. Most
of these customization options are fully integrated into the C++ type
system--making it easy to apply customizations across inheritance
hierarchies, template instantiations, and more. Features include:
- Customized type conversion/marshaling.
- Exception handling.
- Class/structure extension.
- Memory management.
- Ambiguity resolution.
- Template instantiation.
- File import and cross-module linking.
- Code inclusion, helper function support.
- Extensive diagnostics (error/warning messages including fine grained warning suppression).
- Extended SWIG macro handling.
Feedback and questions concerning this site should be posted to the swig-devel mailing list.
Last modified : Tue May 27 19:31:23 2014