| Boost | SWIG |
Simple class; general usage
|
very simple input; single file output file; long compile time; link dependency on Boost
|
input fairly simple; .py and .so output
|
Function overload
|
fails to resolve double and int, but complies without
warning. Works for types which are not implicitly
equivalent in C++.
|
Gets it right.
|
Python overrides virtual functions
|
Gets it right
|
Labelled as "experimental" but seems to work.
|
Templates
|
In both systems, one must fix the set of allowed specializations,
each specialization becoming a new Python type.
|
Passing/returning std::string
|
Just works, out of the box
|
Must explicitly include std_stding.i
|
Operators
|
Automatically exposed
|
Need to do more by hand than in Pyste. some operators difficult
to get to work.
|
Default arguments
|
no Pyste support yet. Default values must be in header.
|
Default values must be in header.
|
Module interdependencies.
|
Converted classes defined in one module automatically available
to others as soon as the former is loaded.
|
Converted classes used on a per-module basis.
|
Iterators
|
Some help is offered, but no Pyste suport yet.
|
Looks like __iter__ must be implemented by hand.
|
Exception Translation
|
Default translator for standard exceptions exists; user can
register custom translators.
|
...
|
Namespaces
|
Namespaces are removed by default; the idea being that the
python module provides the namespace.
|
Conciseness of input
|
With Pyste it's excellent; without Pyste everything must be
declared by hand.
|
Often the default input (essentially two references to the
source header file) is enough.
|
Edit-debug-test cycle
|
Extremely slow to compile; for larger inputs compiler limits
can be reached. Error messages are pure noise - a package
called gstlfilt is rumoured to help with this, but it was
not used in this evaluation.
|
As good as can be expected of a statically compiled language.
|
Documentation
|
Tutorial introduction concisely covers most of what is
necessary. Reference manual confusing.
|
Takes some effort to find relevant sections, but it gives
the impression of being complete.
|
|
|
|