OILS / demo / swig / example.i View on Github | oilshell.org

20 lines, 16 significant
1/* File: example.i */
2%module example
3
4%{
5#define SWIG_FILE_WITH_INIT
6#include "example.h"
7%}
8
9/*
10 * Repeat the prototypes of wrapped functions here
11 * Namespaces are required, but don't seem to affect the generated Python
12 * extension.
13 */
14namespace fanos {
15
16int fact(int n);
17int add(int x, int y);
18void send(int fd, Str* s);
19
20}