Abstract: XDress is an automatic wrapper generator for C/C++ written in pure Python. Currently xdress may generate Python bindings (via Cython) for C++ classes & functions and in-memory wrappers for C++ standard library containers (sets, vectors, maps). In the future, other tools and bindings will be supported.
The purpose of xdress is to create APIs that are a pleasant and natural to use in the target language as the original library. This means that interfaces are translated idiomatically. In some cases this is easy - functions are functions, classes are classes, and so on. In other cases this is more difficult - overloaded functions and templated classes. In still other cases it means that common data structures need special attention - std::maps are not dicts, but std:vectors should be NumPy arrays. In all cases the wrappers should be fast. Unlike other wrapper generators, xdress does its best to fully translate these language constructs.
All of this is done on the backdrop of a modular bring-your-own-parser architecture. To date xdress supports Clang, GCC-XML, and pycparser which makes it the first Python automatic wrapper generator to fully support C++11. Additionally, Python, C, and C++ are only the beginning. Other language plugins may be added with relative ease as interest and demand dictate.
This talk will a discussion on xdress’s parsers, the idiomatic translations it implements, and some type system basics.