Merge remote-tracking branch 'upstream/master' into OCaml-INPUT-OUTPUT-INOUT-primitives
This commit is contained in:
commit
2f48bec666
363 changed files with 5822 additions and 2933 deletions
256
.travis.yml
256
.travis.yml
|
|
@ -5,115 +5,139 @@ matrix:
|
|||
os: linux
|
||||
env: SWIGLANG=
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG= GCC=4.4
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= SWIG_CC=gcc-6 SWIG_CXX=g++-6
|
||||
env: SWIGLANG= GCC=4.6
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=4.7
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=4.8
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=4.9
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=6
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=7
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG= GCC=8
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=csharp
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=d
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=go
|
||||
env: SWIGLANG=go VER=1.3
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=go VER=1.5
|
||||
env: SWIGLANG=go VER=1.8
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=go VER=1.12
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=guile
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=java
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node
|
||||
env: SWIGLANG=javascript ENGINE=node VER=0.10
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node VER=4 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node VER=6 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node VER=8 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node VER=10 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=jsc
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=v8
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=lua
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=lua VER=5.3
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=mzscheme
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=ocaml
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=octave SWIGJOBS=-j2 # 3.8
|
||||
env: SWIGLANG=octave SWIGJOBS=-j2
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=octave SWIGJOBS=-j2 VER=4.0
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=octave SWIGJOBS=-j2 VER=4.2 CPP11=1
|
||||
|
|
@ -128,130 +152,130 @@ matrix:
|
|||
os: linux
|
||||
env: SWIGLANG=perl5
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=php VER=7.0
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=php VER=7.1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=php VER=7.2
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=php VER=7.3
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python # 2.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.2
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.3
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.4
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.5
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.6
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES="-builtin -O"
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP11=1
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin GCC=6 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP11=1 PY3=3 VER=3.7
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin GCC=6 CPP11=1 PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=3 VER=3.4
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=3 VER=3.5
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES="-builtin -O" PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=3 VER=3.7 SWIGOPTPY3=
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-O
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=python SWIG_FEATURES=-O PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=r
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=ruby VER=1.9.3
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=ruby VER=2.0.0
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=ruby VER=2.3.0
|
||||
|
|
@ -261,84 +285,84 @@ matrix:
|
|||
os: linux
|
||||
env: SWIGLANG=scilab
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=tcl
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=csharp SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG=csharp CPP11=1
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=go VER=1.6 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=go SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG=java CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=java SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG=python CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=r CPP11=1 # Note: making 'R CMD SHLIB' use a different compiler is non-trivial
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=ruby SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG=ruby CPP11=1
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=tcl CPP11=1
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=csharp GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=go GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=tcl SWIG_CC=gcc-5 SWIG_CXX=g++-5 CPP11=1
|
||||
env: SWIGLANG=java GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=csharp SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=python GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=go SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=ruby GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=java SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=tcl GCC=6 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=java GCC=7 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=ruby SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=python GCC=7 CPP14=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=tcl SWIG_CC=gcc-6 SWIG_CXX=g++-6 CPP14=1
|
||||
env: SWIGLANG=csharp GCC=8 CPP17=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=java SWIG_CC=gcc-7 SWIG_CXX=g++-7 CPP14=1
|
||||
env: SWIGLANG=java GCC=8 CPP17=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_CC=gcc-7 SWIG_CXX=g++-7 CPP14=1
|
||||
env: SWIGLANG=python GCC=8 CPP17=1 PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=csharp SWIG_CC=gcc-8 SWIG_CXX=g++-8 CPP17=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=java SWIG_CC=gcc-8 SWIG_CXX=g++-8 CPP17=1
|
||||
sudo: required
|
||||
dist: trusty
|
||||
- os: linux
|
||||
env: SWIGLANG=python SWIG_CC=gcc-8 SWIG_CXX=g++-8 CPP17=1 PY3=3 VER=3.7
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: osx
|
||||
env: SWIGLANG=
|
||||
|
|
@ -377,12 +401,12 @@ matrix:
|
|||
env: SWIGLANG=tcl
|
||||
|
||||
allow_failures:
|
||||
# Deprecated functions causing build failure since upgrade from Node v10.11.0 to v10.12.0
|
||||
# seg fault in director_basic testcase
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=javascript ENGINE=node VER=10 CPP11=1
|
||||
env: SWIGLANG=php VER=7.2
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
# Sometimes hits the Travis 50 minute time limit
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
|
|
@ -394,33 +418,29 @@ matrix:
|
|||
os: linux
|
||||
env: SWIGLANG=mzscheme
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
- compiler: gcc
|
||||
os: linux
|
||||
env: SWIGLANG=ocaml
|
||||
sudo: required
|
||||
dist: trusty
|
||||
dist: xenial
|
||||
|
||||
before_install:
|
||||
- date -u
|
||||
- uname -a
|
||||
- if test "$TRAVIS_OS_NAME" = "linux"; then lscpu && cat /proc/cpuinfo | grep "model name" && cat /proc/meminfo | grep MemTotal; fi
|
||||
- if test "$TRAVIS_OS_NAME" = "osx"; then sysctl -a | grep brand_string; fi
|
||||
# Travis overrides CC environment with compiler predefined values
|
||||
- if test -n "$SWIG_CC"; then export CC="$SWIG_CC"; fi
|
||||
- if test -n "$SWIG_CXX"; then export CXX="$SWIG_CXX"; fi
|
||||
# Travis overrides CC environment with compiler predefined values
|
||||
- if test -n "$GCC"; then export CC="gcc-$GCC" && export CXX="g++-$GCC"; fi
|
||||
install:
|
||||
- if test "$TRAVIS_OS_NAME" = "linux"; then source Tools/travis-linux-install.sh; fi
|
||||
- if test "$TRAVIS_OS_NAME" = "osx"; then source Tools/travis-osx-install.sh; fi
|
||||
- ls -la $(which $CC) $(which $CXX) && $CC --version && $CXX --version
|
||||
script:
|
||||
- echo 'Configuring...' && echo -en 'travis_fold:start:script.1\\r'
|
||||
- if test -n "$CPP11"; then CONFIGOPTS+=(--enable-cpp11-testing --without-maximum-compile-warnings "CXXFLAGS=-std=c++11 -Wall -Wextra" "CFLAGS=-std=c11 -Wall -Wextra") && export CSTD=c11 && export CPPSTD=c++11; fi
|
||||
- if test -n "$CPP14"; then CONFIGOPTS+=(--enable-cpp11-testing --without-maximum-compile-warnings "CXXFLAGS=-std=c++14 -Wall -Wextra" "CFLAGS=-std=c11 -Wall -Wextra") && export CSTD=c11 && export CPPSTD=c++14; fi
|
||||
- if test -n "$CPP17"; then CONFIGOPTS+=(--enable-cpp11-testing --without-maximum-compile-warnings "CXXFLAGS=-std=c++17 -Wall -Wextra" "CFLAGS=-std=c17 -Wall -Wextra") && export CSTD=c17 && export CPPSTD=c++17; fi
|
||||
- ls -la $(which $CC)
|
||||
- ls -la $(which $CXX)
|
||||
- $CC --version
|
||||
- $CXX --version
|
||||
script:
|
||||
- echo 'Configuring...' && echo -en 'travis_fold:start:script.1\\r'
|
||||
- if test -n "$SWIGLANG"; then CONFIGOPTS+=(--without-alllang --with-$WITHLANG); fi
|
||||
- echo "${CONFIGOPTS[@]}"
|
||||
- ./autogen.sh && mkdir -p build/build && cd build/build && ../../configure "${CONFIGOPTS[@]}"
|
||||
|
|
|
|||
20
ANNOUNCE
20
ANNOUNCE
|
|
@ -1,8 +1,8 @@
|
|||
*** ANNOUNCE: SWIG 4.0.0 (in progress) ***
|
||||
*** ANNOUNCE: SWIG 4.0.1 (in progress) ***
|
||||
|
||||
http://www.swig.org
|
||||
|
||||
We're pleased to announce SWIG-4.0.0, the latest SWIG release.
|
||||
We're pleased to announce SWIG-4.0.1, the latest SWIG release.
|
||||
|
||||
What is SWIG?
|
||||
=============
|
||||
|
|
@ -10,13 +10,11 @@ What is SWIG?
|
|||
SWIG is a software development tool that reads C/C++ header files and
|
||||
generates the wrapper code needed to make C and C++ code accessible
|
||||
from other programming languages including Perl, Python, Tcl, Ruby,
|
||||
PHP, C#, Go, Java, Javascript, Lua, Scheme (Guile, MzScheme),
|
||||
D, Ocaml, Octave, R, Scilab.
|
||||
SWIG can also export its parse tree in
|
||||
the form of XML. Major applications of SWIG
|
||||
include generation of scripting language extension modules, rapid
|
||||
prototyping, testing, and user interface development for large
|
||||
C/C++ systems.
|
||||
PHP, C#, Go, Java, Javascript, Lua, Scheme (Guile, MzScheme), D,
|
||||
Ocaml, Octave, R, Scilab. SWIG can also export its parse tree in
|
||||
the form of XML. Major applications of SWIG include generation of
|
||||
scripting language extension modules, rapid prototyping, testing,
|
||||
and user interface development for large C/C++ systems.
|
||||
|
||||
Release Notes
|
||||
=============
|
||||
|
|
@ -27,11 +25,11 @@ Availability
|
|||
============
|
||||
The release is available for download on Sourceforge at
|
||||
|
||||
http://prdownloads.sourceforge.net/swig/swig-4.0.0.tar.gz
|
||||
http://prdownloads.sourceforge.net/swig/swig-4.0.1.tar.gz
|
||||
|
||||
A Windows version is also available at
|
||||
|
||||
http://prdownloads.sourceforge.net/swig/swigwin-4.0.0.zip
|
||||
http://prdownloads.sourceforge.net/swig/swigwin-4.0.1.zip
|
||||
|
||||
Please report problems with this release to the swig-devel mailing list,
|
||||
details at http://www.swig.org/mail.html.
|
||||
|
|
|
|||
1384
CHANGES.current
1384
CHANGES.current
File diff suppressed because it is too large
Load diff
|
|
@ -19,6 +19,7 @@ Active SWIG Developers:
|
|||
Oliver Buchtala (oliver.buchtala@gmail.com) (Javascript)
|
||||
Neha Narang (narangneha03@gmail.com) (Javascript)
|
||||
Simon Marchetto (simon.marchetto@scilab-enterprises.com) (Scilab)
|
||||
Zackery Spytz (zspytz@gmail.com) (OCaml, SWIG core)
|
||||
|
||||
Past SWIG developers and major contributors include:
|
||||
Dave Beazley (dave-swig@dabeaz.com) (SWIG core, Python, Tcl, Perl)
|
||||
|
|
@ -28,7 +29,7 @@ Past SWIG developers and major contributors include:
|
|||
Mikel Bancroft (mikel@franz.com) (Allegro CL)
|
||||
Surendra Singhi (efuzzyone@netscape.net) (CLISP, CFFI)
|
||||
Marcelo Matus (mmatus@acms.arizona.edu) (SWIG core, Python, UTL[python,perl,tcl,ruby])
|
||||
Art Yerkes (ayerkes@speakeasy.net) (Ocaml)
|
||||
Art Yerkes (ayerkes@speakeasy.net) (OCaml)
|
||||
Lyle Johnson (lyle@users.sourceforge.net) (Ruby)
|
||||
Charlie Savage (cfis@interserv.com) (Ruby)
|
||||
Thien-Thi Nguyen (ttn@glug.org) (build/test/misc)
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ This chapter contains a few Android specific notes and examples.
|
|||
|
||||
|
||||
<p>
|
||||
The examples require the <a href="http://developer.android.com/sdk/index.html">Android SDK</a> and <a href="http://developer.android.com/tools/sdk/ndk/index.html">Android NDK</a> which can be installed as per instructions in the links.
|
||||
The examples require the <a href="https://developer.android.com/sdk/">Android SDK</a> and <a href="https://developer.android.com/ndk/">Android NDK</a> which can be installed as per instructions in the links.
|
||||
The Eclipse version is not required for these examples as just the command line tools are used (shown for Linux as the host, but Windows will be very similar, if not identical in most places).
|
||||
Add the SDK tools and NDK tools to your path and create a directory somewhere for your Android projects (adjust PATH as necessary to where you installed the tools):
|
||||
</p>
|
||||
|
|
@ -326,7 +326,7 @@ include $(BUILD_SHARED_LIBRARY)
|
|||
</div>
|
||||
|
||||
<p>
|
||||
See the <a href="http://developer.android.com/sdk/ndk/index.html">Android NDK documentation</a> for more on the NDK build system and getting started with the NDK.
|
||||
See the <a href="https://developer.android.com/ndk/">Android NDK documentation</a> for more on the NDK build system and getting started with the NDK.
|
||||
A simple invocation of ndk-build will compile the .c files and generate a shared object/system library. Output will be similar to:
|
||||
</p>
|
||||
|
||||
|
|
|
|||
|
|
@ -458,7 +458,7 @@ Thanks to the following people for their contributions to ccache
|
|||
|
||||
<p>
|
||||
ccache was written by Andrew Tridgell
|
||||
<a href="http://samba.org/~tridge/">http://samba.org/~tridge/</a>.
|
||||
<a href="https://www.samba.org/~tridge/">https://www.samba.org/~tridge/</a>.
|
||||
ccache was adapted to create ccache-swig for use with SWIG by William Fulton.
|
||||
<p>
|
||||
If you wish to report a problem or make a suggestion then please email
|
||||
|
|
|
|||
|
|
@ -64,15 +64,15 @@ The wrapper code implementation uses C# and the Platform Invoke (PInvoke) interf
|
|||
The PInvoke interface has been chosen over Microsoft's Managed C++ interface as it is portable to both Microsoft Windows and non-Microsoft platforms.
|
||||
PInvoke is part of the ECMA/ISO C# specification.
|
||||
It is also better suited for robust production environments due to the Managed C++ flaw called the
|
||||
<a href="http://msdn.microsoft.com/en-us/library/aa290048(VS.71).aspx">Mixed DLL Loading Problem</a>.
|
||||
<a href="https://msdn.microsoft.com/en-us/ie/aa290048(v=vs.94)">Mixed DLL Loading Problem</a>.
|
||||
SWIG C# works equally well on non-Microsoft operating systems such as Linux, Solaris and Apple Mac using
|
||||
<a href="http://www.mono-project.com/Main_Page">Mono</a> and <a href="http://www.dotgnu.org/pnet.html">Portable.NET</a>.
|
||||
<a href="https://www.mono-project.com/Main_Page/">Mono</a> and <a href="http://www.dotgnu.org/pnet.html">Portable.NET</a>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To get the most out of this chapter an understanding of interop is required.
|
||||
The <a href="http://msdn.microsoft.com">Microsoft Developer Network (MSDN)</a> has a good reference guide in a section titled "Interop Marshaling".
|
||||
Monodoc, available from the Mono project, has a very useful section titled <a href="http://www.mono-project.com/docs/advanced/pinvoke/">Interop with native libraries</a>.
|
||||
The <a href="https://msdn.microsoft.com">Microsoft Developer Network (MSDN)</a> has a good reference guide in a section titled "Interop Marshaling".
|
||||
Monodoc, available from the Mono project, has a very useful section titled <a href="https://www.mono-project.com/docs/advanced/pinvoke/">Interop with native libraries</a>.
|
||||
</p>
|
||||
|
||||
<H3><a name="CSharp_introduction_swig2_compatibility">22.1.1 SWIG 2 Compatibility</a></H3>
|
||||
|
|
@ -232,8 +232,8 @@ javacode -> cscode
|
|||
javaimports -> csimports
|
||||
javabody -> csbody
|
||||
javafinalize -> csfinalize
|
||||
javadestruct -> csdestruct
|
||||
javadestruct_derived -> csdestruct_derived
|
||||
javadestruct -> csdisposing and csdispose
|
||||
javadestruct_derived -> csdisposing_derived and csdispose_derived
|
||||
javainterfacecode -> csinterfacecode
|
||||
</pre></div>
|
||||
|
||||
|
|
@ -643,7 +643,7 @@ passing a direct reference as described in the next section.
|
|||
|
||||
<p>
|
||||
For more information on the subject, see the
|
||||
<a href="http://msdn.microsoft.com/en-us/library/z6cfh6e6(VS.80).aspx">Default Marshaling for Arrays</a> article
|
||||
<a href="https://docs.microsoft.com/en-us/dotnet/framework/interop/default-marshaling-for-arrays">Default Marshaling for Arrays</a> article
|
||||
on MSDN.
|
||||
</p>
|
||||
|
||||
|
|
@ -763,7 +763,7 @@ another thread may produce enough garbage to trigger garbage collection.
|
|||
</p>
|
||||
|
||||
<p>
|
||||
For more information, see the <a href="http://msdn.microsoft.com/en-us/library/f58wzh21(VS.80).aspx">fixed statement</a> in the C# language reference.
|
||||
For more information, see the <a href="https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/fixed-statement">fixed statement</a> in the C# language reference.
|
||||
</p>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -647,6 +647,10 @@
|
|||
<li><a href="Doxygen.html#Doxygen_python_unsupported_tags">Unsupported tags</a>
|
||||
<li><a href="Doxygen.html#Doxygen_python_further_details">Further details</a>
|
||||
</ul>
|
||||
<li><a href="Doxygen.html#Doxygen_troubleshooting">Troubleshooting</a>
|
||||
<ul>
|
||||
<li><a href="Doxygen.html#troubleshooting_ifndef">Problem with conditional compilation</a>
|
||||
</ul>
|
||||
<li><a href="Doxygen.html#Doxygen_developer_details">Developer information</a>
|
||||
<ul>
|
||||
<li><a href="Doxygen.html#Doxygen_translator_design">Doxygen translator design</a>
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@
|
|||
<H2><a name="D_command_line_invocation">23.2 Command line invocation</a></H2>
|
||||
|
||||
|
||||
<p>To activate the D module, pass the <tt>-d</tt> option to SWIG at the command line. The same standard command line switches as with any other language module are available, plus the following D specific ones:</p>
|
||||
<p>To activate the D module, pass the <tt>-d</tt> option to SWIG at the command line. The same standard command line options as with any other language module are available, plus the following D specific ones:</p>
|
||||
|
||||
<dl>
|
||||
<dt><tt>-d2</tt></dt>
|
||||
|
|
@ -66,8 +66,8 @@
|
|||
|
||||
<dt><a name="D_splitproxy"></a><tt>-splitproxy</tt></dt>
|
||||
<dd>
|
||||
<p>By default, SWIG generates two D modules: the <em>proxy</em> module, named like the source module (either specified via the <tt>%module</tt> directive or via the <tt>module</tt> command line switch), which contains all the proxy classes, functions, enums, etc., and the <em>intermediary</em> module (named like the proxy module, but suffixed with <tt>_im</tt>), which contains all the <tt>extern(C)</tt> function declarations and other private parts only used internally by the proxy module.</p>
|
||||
<p>If the split proxy mode is enabled by passing this switch at the command line, all proxy classes and enums are emitted to their own D module instead. The main proxy module only contains free functions and constants in this case.</p>
|
||||
<p>By default, SWIG generates two D modules: the <em>proxy</em> module, named like the source module (either specified via the <tt>%module</tt> directive or via the <tt>module</tt> command line option), which contains all the proxy classes, functions, enums, etc., and the <em>intermediary</em> module (named like the proxy module, but suffixed with <tt>_im</tt>), which contains all the <tt>extern(C)</tt> function declarations and other private parts only used internally by the proxy module.</p>
|
||||
<p>If the split proxy mode is enabled by passing this option at the command line, all proxy classes and enums are emitted to their own D module instead. The main proxy module only contains free functions and constants in this case.</p>
|
||||
</dd>
|
||||
|
||||
<dt><tt>-package <pkg></tt></dt>
|
||||
|
|
@ -77,7 +77,7 @@
|
|||
|
||||
<dt><tt>-wrapperlibrary <wl></tt></dt>
|
||||
<dd>
|
||||
<p>The code SWIG generates to dynamically load the C/C++ wrapper layer looks for a library called <tt>$module_wrap</tt> by default. With this switch, you can override the name of the file the wrapper code loads at runtime (the <tt>lib</tt> prefix and the suffix for shared libraries are appended automatically, depending on the OS).</p>
|
||||
<p>The code SWIG generates to dynamically load the C/C++ wrapper layer looks for a library called <tt>$module_wrap</tt> by default. With this option, you can override the name of the file the wrapper code loads at runtime (the <tt>lib</tt> prefix and the suffix for shared libraries are appended automatically, depending on the OS).</p>
|
||||
<p>This might especially be useful if you want to invoke SWIG several times on separate modules, but compile the resulting code into a single shared library.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
|
|
@ -107,8 +107,8 @@
|
|||
csimports <-> dimports
|
||||
csbody <-> dbody
|
||||
csfinalize <-> ddestructor
|
||||
csdestruct <-> ddispose
|
||||
csdestruct_derived <-> ddispose_derived
|
||||
csdisposing <-> ddispose
|
||||
csdisposing_derived <-> ddispose_derived
|
||||
</pre></div>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -37,6 +37,10 @@
|
|||
<li><a href="#Doxygen_python_unsupported_tags">Unsupported tags</a>
|
||||
<li><a href="#Doxygen_python_further_details">Further details</a>
|
||||
</ul>
|
||||
<li><a href="#Doxygen_troubleshooting">Troubleshooting</a>
|
||||
<ul>
|
||||
<li><a href="#troubleshooting_ifndef">Problem with conditional compilation</a>
|
||||
</ul>
|
||||
<li><a href="#Doxygen_developer_details">Developer information</a>
|
||||
<ul>
|
||||
<li><a href="#Doxygen_translator_design">Doxygen translator design</a>
|
||||
|
|
@ -63,13 +67,13 @@ supported.
|
|||
<p>
|
||||
The Doxygen Translation module of SWIG adds an extra layer of
|
||||
functionality to SWIG, allowing automated translation of <a href=
|
||||
"http://www.stack.nl/~dimitri/doxygen/">Doxygen</a> formatted comments
|
||||
"http://www.doxygen.nl/manual/">Doxygen</a> formatted comments
|
||||
from input files into a documentation language more suited for the
|
||||
target language. Currently this module only translates into Javadoc
|
||||
and Pydoc for the SWIG Java and Python modules.
|
||||
Other extensions could be added at a later date.
|
||||
The Doxygen Translation module originally started as
|
||||
a <a href="http://code.google.com/soc/2008/">Google Summer of
|
||||
a <a href="https://developers.google.com/open-source/gsoc/2008/">Google Summer of
|
||||
Code</a> proposal from Summer 2008.
|
||||
</p>
|
||||
|
||||
|
|
@ -79,14 +83,14 @@ Code</a> proposal from Summer 2008.
|
|||
<p>
|
||||
To make use of the comment translation system, your documentation
|
||||
comments must be in properly formatted <a href=
|
||||
"http://www.stack.nl/~dimitri/doxygen/">Doxygen.</a> Doxygen comments can be
|
||||
"http://www.doxygen.nl/manual/">Doxygen.</a> Doxygen comments can be
|
||||
present in your main SWIG interface file or any header file that it
|
||||
imports. You are advised to be validate that your comments compile
|
||||
properly with Doxygen before you try to translate them. Doxygen
|
||||
itself is a more comprehensive tool and can provide you better feedback for
|
||||
correcting any syntax errors that may be present. Please look at
|
||||
Doxygen's <a href=
|
||||
"http://www.stack.nl/~dimitri/doxygen/docblocks.html"> Documenting the
|
||||
"http://www.doxygen.nl/manual/docblocks.html"> Documenting the
|
||||
code</a> for the full comment format specifications. However, SWIG's
|
||||
Doxygen parser will still report many errors and warnings found
|
||||
in comments (like unterminated strings or missing ending tags).
|
||||
|
|
@ -94,7 +98,7 @@ in comments (like unterminated strings or missing ending tags).
|
|||
|
||||
<p>
|
||||
Currently, the whole subset of Doxygen comment styles is supported
|
||||
(See <a href="http://www.stack.nl/~dimitri/doxygen/docblocks.html">
|
||||
(See <a href="http://www.doxygen.nl/manual/docblocks.html">
|
||||
Documenting the code</a>). Here they are:
|
||||
</p>
|
||||
|
||||
|
|
@ -194,7 +198,7 @@ These structural commands are stripped out by SWIG and are not assigned to anyth
|
|||
|
||||
<p>
|
||||
Doxygen comments translation is disabled by default and needs to be explicitly
|
||||
enabled using the command line <tt>-doxygen</tt> switch for the languages that
|
||||
enabled using the command line <tt>-doxygen</tt> option for the languages that
|
||||
do support it (currently Java and Python).
|
||||
</p>
|
||||
|
||||
|
|
@ -293,7 +297,7 @@ make much sense for the other languages without explicit ownership management.
|
|||
<p>
|
||||
Doxygen syntax is rather rich and, in addition to simple commands such as
|
||||
<tt>@transferfull</tt>, it is also possible to define commands with arguments.
|
||||
As explained in <a href="http://www.stack.nl/~dimitri/doxygen/manual/commands.html">Doxygen documentation</a>,
|
||||
As explained in <a href="http://www.doxygen.nl/manual/commands.html">Doxygen documentation</a>,
|
||||
the arguments can have a range of a single word, everything until the end of
|
||||
line or everything until the end of the next paragraph. Currently, only the "end
|
||||
of line" case is supported using the <tt>range="line"</tt> argument of the
|
||||
|
|
@ -818,7 +822,7 @@ Here is the list of all Doxygen tags and the description of how they are transla
|
|||
<p>
|
||||
Doxygen has a wealth of tags such as @latexonly that have no
|
||||
equivalent in Javadoc (all supported tags are listed in
|
||||
<a href="http://docs.oracle.com/javase/7/docs/technotes/tools/windows/javadoc.html">Javadoc documentation</a>).
|
||||
<a href="https://docs.oracle.com/javase/7/docs/technotes/tools/windows/javadoc.html">Javadoc documentation</a>).
|
||||
As a result several tags have no
|
||||
translation or particular use, such as some linking and section tags.
|
||||
These are suppressed with their content just printed out (if the tag has any
|
||||
|
|
@ -1223,9 +1227,9 @@ completely (doxygen:notranslate feature). Then SWIG will just copy
|
|||
the comments to the proxy file and reformat them if needed, but all
|
||||
the comment content will be left as is. As Doxygen doesn't support
|
||||
special commands in Python comments
|
||||
(see <a href="http://www.stack.nl/~dimitri/doxygen/docblocks.html#pythonblocks">Doxygen
|
||||
(see <a href="http://www.doxygen.nl/manual/docblocks.html#pythonblocks">Doxygen
|
||||
docs</a>), you may want to use some tool like doxypy
|
||||
(<a href="http://code.foosel.org/doxypy">http://code.foosel.org/doxypy</a>)
|
||||
(<a href="https://pypi.org/project/doxypy/">doxypy</a>)
|
||||
to do the work.
|
||||
</p>
|
||||
|
||||
|
|
@ -1634,14 +1638,76 @@ Here is the list of these tags:
|
|||
TO BE ADDED.
|
||||
</p>
|
||||
|
||||
<H2><a name="Doxygen_developer_details">17.5 Developer information</a></H2>
|
||||
<H2><a name="Doxygen_troubleshooting">17.5 Troubleshooting</a></H2>
|
||||
|
||||
|
||||
<p>
|
||||
When running SWIG with command line option <tt>-doxygen</tt>, it may happen
|
||||
that SWIG will fail to parse the code, which is valid C++ code and
|
||||
is parsed without problems without the option. The problem is,
|
||||
that Doxygen comments are not tokens (the C/C++ compiler actually never
|
||||
sees them) and that they can appear anywhere in the code. That's why it is
|
||||
practically impossible to handle all corner cases with the parser.
|
||||
However, these problems can usually be avoided by minor changes in the
|
||||
code or comment. Known problems and solutions are shown in this section.
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
Recommended approach is to first run SWIG without command line
|
||||
option <tt>-doxygen</tt>. When it successfully processes the code,
|
||||
include the option and fix problems with Doxygen comments.
|
||||
</p>
|
||||
|
||||
|
||||
<H3><a name="troubleshooting_ifndef">17.5.1 Problem with conditional compilation</a></H3>
|
||||
|
||||
|
||||
<p>
|
||||
Inserting a conditional compilation preprocessor directive between a
|
||||
Doxygen comment and a commented item may break parsing:
|
||||
</p>
|
||||
|
||||
|
||||
<div class="code"><pre>
|
||||
class A {
|
||||
/**
|
||||
* Some func.
|
||||
*/
|
||||
<font color='#ff0000'>#ifndef SWIG</font>
|
||||
void myfunc()
|
||||
{
|
||||
}
|
||||
#endif
|
||||
};
|
||||
</pre></div>
|
||||
|
||||
<p>
|
||||
The solution is to move the directive above the comment:
|
||||
</p>
|
||||
|
||||
<div class="code"><pre>
|
||||
class A {
|
||||
<font color='#00d000'>#ifndef SWIG</font>
|
||||
/**
|
||||
* Some func.
|
||||
*/
|
||||
void myfunc()
|
||||
{
|
||||
}
|
||||
#endif
|
||||
};
|
||||
</pre></div>
|
||||
|
||||
|
||||
<H2><a name="Doxygen_developer_details">17.6 Developer information</a></H2>
|
||||
|
||||
|
||||
<p>
|
||||
This section contains information for developers enhancing the Doxygen translator.
|
||||
</p>
|
||||
|
||||
<H3><a name="Doxygen_translator_design">17.5.1 Doxygen translator design</a></H3>
|
||||
<H3><a name="Doxygen_translator_design">17.6.1 Doxygen translator design</a></H3>
|
||||
|
||||
|
||||
<p>
|
||||
|
|
@ -1667,11 +1733,11 @@ class for translation into the target documentation language. For
|
|||
example, <tt>JavaDocConverter</tt> is the Javadoc module class.
|
||||
</p>
|
||||
|
||||
<H3><a name="Doxygen_debugging_commands">17.5.2 Debugging the Doxygen parser and translator</a></H3>
|
||||
<H3><a name="Doxygen_debugging_commands">17.6.2 Debugging the Doxygen parser and translator</a></H3>
|
||||
|
||||
|
||||
<p>
|
||||
There are two handy command line switches, that enable lots of
|
||||
There are two handy command line options, that enable lots of
|
||||
detailed debug information printing.
|
||||
</p>
|
||||
|
||||
|
|
@ -1680,7 +1746,7 @@ detailed debug information printing.
|
|||
-debug-doxygen-translator - Display Doxygen translator module debugging information
|
||||
</pre></div>
|
||||
|
||||
<H3><a name="Doxygen_tests">17.5.3 Tests</a></H3>
|
||||
<H3><a name="Doxygen_tests">17.6.3 Tests</a></H3>
|
||||
|
||||
|
||||
<p>
|
||||
|
|
@ -1732,7 +1798,7 @@ Runtime tests in Python are just plain string comparisons of the __doc__
|
|||
properties.
|
||||
</p>
|
||||
|
||||
<H2><a name="Doxygen_language_extension">17.6 Extending to other languages</a></H2>
|
||||
<H2><a name="Doxygen_language_extension">17.7 Extending to other languages</a></H2>
|
||||
|
||||
|
||||
<p>
|
||||
|
|
|
|||
|
|
@ -125,16 +125,15 @@ Go distribution. To generate code for gccgo, you should also use the
|
|||
</p>
|
||||
|
||||
<p>
|
||||
When using the <tt>-cgo</tt> option, SWIG will generate files that can be used
|
||||
directly by <tt>go build</tt>. Starting with the Go 1.5 distribution the
|
||||
<tt>-cgo</tt> option has to be given. Put your SWIG interface file in a
|
||||
directory under GOPATH/src, and give it a name that does <b>not</b> end in the
|
||||
.swig or .swigcxx extension. Typically the SWIG interface file extension is .i
|
||||
in this case.
|
||||
By default SWIG will generate files that can be used directly
|
||||
by <tt>go build</tt>. This requires Go 1.2 or later. Put your SWIG
|
||||
interface file in a directory under GOPATH/src, and give it a name
|
||||
that does <b>not</b> end in the .swig or .swigcxx extension.
|
||||
Typically the SWIG interface file extension is .i in this case.
|
||||
</p>
|
||||
|
||||
<div class="code"><pre>
|
||||
% swig -go -cgo example.i
|
||||
% swig -go example.i
|
||||
% go install
|
||||
</pre></div>
|
||||
|
||||
|
|
@ -144,15 +143,16 @@ usual.
|
|||
</p>
|
||||
|
||||
<p>
|
||||
To use SWIG without the <tt>-cgo</tt> option, more steps are required. Recall
|
||||
that this only works with Go versions before 1.5. When using Go version 1.2 or
|
||||
later, or when using gccgo, the code generated by SWIG can be linked directly
|
||||
into the Go program. A typical command sequence when using the Go compiler of
|
||||
the Go distribution would look like this:
|
||||
SWIG can be used without cgo, via the <tt>-no-cgo</tt> option, but
|
||||
more steps are required. This only works with Go versions before 1.5.
|
||||
When using Go version 1.2 or later, or when using gccgo, the code
|
||||
generated by SWIG can be linked directly into the Go program. A
|
||||
typical command sequence when using the Go compiler of the Go
|
||||
distribution would look like this:
|
||||
</p>
|
||||
|
||||
<div class="code"><pre>
|
||||
% swig -go example.i
|
||||
% swig -go -no-cgo example.i
|
||||
% gcc -c code.c # The C library being wrapped.
|
||||
% gcc -c example_wrap.c
|
||||
% go tool 6g example.go
|
||||
|
|
@ -169,7 +169,7 @@ sequence for this approach would look like this:
|
|||
</p>
|
||||
|
||||
<div class="code"><pre>
|
||||
% swig -go -use-shlib example.i
|
||||
% swig -go -no-cgo -use-shlib example.i
|
||||
% gcc -c -fpic example.c
|
||||
% gcc -c -fpic example_wrap.c
|
||||
% gcc -shared example.o example_wrap.o -o example.so
|
||||
|
|
@ -200,10 +200,15 @@ swig -go -help
|
|||
|
||||
<tr>
|
||||
<td>-cgo</td>
|
||||
<td>Generate files to be used as input for the Go cgo tool. This
|
||||
option is required for Go 1.5 and later, and works for Go 1.2 and
|
||||
later. In the future this option will likely become the
|
||||
default.</td>
|
||||
<td>Generate files to be used as input for the Go cgo tool. This is
|
||||
the default.</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>-no-cgo</td>
|
||||
<td>Generate files that can be used directly, rather than via the Go
|
||||
cgo tool. This option does not work with Go 1.5 or later. It is
|
||||
required for versions of Go before 1.2.</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
|
|
@ -261,6 +266,13 @@ swig -go -help
|
|||
ignored.</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>-import-prefix <prefix></td>
|
||||
<td>A prefix to add when turning a %import prefix in the SWIG
|
||||
interface file into an import statement in the Go file. For
|
||||
example, with <code>-import-prefix mymodule</code>, a SWIG
|
||||
interface file <code>%import mypackage</code> will become a Go
|
||||
import statement <code>import "mymodule/mypackage"</code>.</td>
|
||||
</table>
|
||||
|
||||
|
||||
|
|
@ -268,11 +280,11 @@ swig -go -help
|
|||
|
||||
|
||||
<p>There are two different approaches to generating wrapper files,
|
||||
controlled by SWIG's <tt>-cgo</tt> option. The <tt>-cgo</tt> option
|
||||
works with Go version 1.2 or later. It is required when using Go
|
||||
version 1.5 or later.</p>
|
||||
controlled by SWIG's <tt>-no-cgo</tt> option. The <tt>-no-cgo</tt>
|
||||
option only works with version of Go before 1.5. It is required
|
||||
when using versions of Go before 1.2.</p>
|
||||
|
||||
<p>With or without the <tt>-cgo</tt> option, SWIG will generate the
|
||||
<p>With or without the <tt>-no-cgo</tt> option, SWIG will generate the
|
||||
following files when generating wrapper code:</p>
|
||||
|
||||
<ul>
|
||||
|
|
@ -296,8 +308,8 @@ or C++ compiler.
|
|||
</li>
|
||||
</ul>
|
||||
|
||||
<p>When neither the <tt>-cgo</tt> nor the <tt>-gccgo</tt> option is
|
||||
used, SWIG will also generate an additional file:</p>
|
||||
<p>When the <tt>-no-cgo</tt> option is used, and the <tt>-gccgo</tt>
|
||||
option is not used, SWIG will also generate an additional file:</p>
|
||||
|
||||
<ul>
|
||||
<li>
|
||||
|
|
@ -785,7 +797,9 @@ In order to override virtual methods on a C++ class with Go methods the
|
|||
<tt>NewDirectorClassName</tt> constructor functions receives a
|
||||
<tt>DirectorInterface</tt> argument. The methods in the <tt>
|
||||
DirectorInterface</tt> are a subset of the public and protected virtual methods
|
||||
of the C++ class. If the <tt>DirectorInterface</tt> contains a method with a
|
||||
of the C++ class.
|
||||
Virtual methods that have a final specifier are unsurprisingly excluded.
|
||||
If the <tt>DirectorInterface</tt> contains a method with a
|
||||
matching signature to a virtual method of the C++ class then the virtual C++
|
||||
method will be overwritten with the Go method. As Go doesn't support protected
|
||||
methods all overridden protected virtual C++ methods will be public in Go.
|
||||
|
|
@ -1289,7 +1303,7 @@ fraction := modulename.Modf(5.0, ptr)
|
|||
</pre>
|
||||
</div>
|
||||
<p>Since this is ugly, you may want to wrap the swig-generated API with
|
||||
some <a href="#Embedded_go_code">additional functions written in go</a> that
|
||||
some <a href="#Go_adding_additional_code">additional functions written in go</a> that
|
||||
hide the ugly details.</p>
|
||||
|
||||
<p>There are no <code>char *OUTPUT</code> typemaps. However you can
|
||||
|
|
|
|||
|
|
@ -163,7 +163,7 @@ This ability to interface C/C++ to many different target languages is one of SWI
|
|||
|
||||
<p>
|
||||
SWIG is very broadly composed of two components.
|
||||
A core component creates a parse tree from the input C/C++ and SWIG directives (extensions to C/C++).
|
||||
A core component creates a parse tree from the input ISO C/C++ and SWIG directives (extensions to the C/C++ standards).
|
||||
The parse tree is then passed to a second component, one of the target language modules for generating code specific to a higher level language.
|
||||
SWIG supports many different target languages.
|
||||
These target languages are given a status of either Supported or Experimental.
|
||||
|
|
@ -273,7 +273,7 @@ extern int my_mod(int n, int m);
|
|||
</pre></div>
|
||||
|
||||
<p>
|
||||
The interface file contains ANSI C function prototypes and variable
|
||||
The interface file contains ISO C function prototypes and variable
|
||||
declarations. The <tt>%module</tt> directive defines the name of the
|
||||
module that will be created by SWIG. The <tt>%{ %}</tt> block
|
||||
provides a location for inserting additional code, such as C header
|
||||
|
|
@ -400,7 +400,7 @@ major features include:
|
|||
|
||||
<ul>
|
||||
<li>Full C99 preprocessing.
|
||||
<li>All ANSI C and C++ datatypes.
|
||||
<li>All ISO C and C++ datatypes.
|
||||
<li>Functions, variables, and constants.
|
||||
<li>Classes.
|
||||
<li>Single and multiple inheritance.
|
||||
|
|
@ -464,7 +464,7 @@ for further information on this and other Autoconf macros.
|
|||
</p>
|
||||
|
||||
<p>
|
||||
There is growing support for SWIG in some build tools, for example <a href="http://cmake.org">CMake</a>
|
||||
There is growing support for SWIG in some build tools, for example <a href="https://cmake.org">CMake</a>
|
||||
is a cross-platform, open-source build manager with built in support for SWIG. CMake can detect the SWIG executable
|
||||
and many of the target language libraries for linking against.
|
||||
CMake knows how to build shared libraries and loadable modules on many different operating systems.
|
||||
|
|
@ -531,7 +531,7 @@ to work with complicated and unusual C/C++ applications.
|
|||
Ironically, the freedom that SWIG provides is countered by an
|
||||
extremely conservative approach to code generation. At its core, SWIG
|
||||
tries to distill even the most advanced C++ code down to a small
|
||||
well-defined set of interface building techniques based on ANSI C
|
||||
well-defined set of interface building techniques based on ISO C
|
||||
programming. Because of this, you will find that SWIG interfaces can
|
||||
be easily compiled by virtually every C/C++ compiler and that they can
|
||||
be used on any platform. Again, this is an important part of staying out
|
||||
|
|
|
|||
|
|
@ -477,7 +477,7 @@ Exception in thread "main" java.lang.UnsatisfiedLinkError: exampleJNI.gcd(II)I
|
|||
<p>
|
||||
where <tt>gcd</tt> is the missing JNI function that SWIG generated into the wrapper file.
|
||||
Also make sure you pass all of the required libraries to the linker.
|
||||
The <tt>java -verbose:jni</tt> commandline switch is also a great way to get more information on unresolved symbols.
|
||||
The <tt>java -verbose:jni</tt> commandline option is also a great way to get more information on unresolved symbols.
|
||||
One last piece of advice is to beware of the common faux pas of having more than one native library version in your path.
|
||||
</p>
|
||||
|
||||
|
|
@ -645,7 +645,7 @@ java::
|
|||
<p>
|
||||
To build the DLL and compile the java code, run NMAKE (you may need to run <tt>vcvars32</tt> first).
|
||||
This is a pretty simplistic Makefile, but hopefully its enough to get you started.
|
||||
Of course you may want to make changes for it to work for C++ by adding in the -c++ command line switch for swig and replacing .c with .cxx.
|
||||
Of course you may want to make changes for it to work for C++ by adding in the -c++ command line option for swig and replacing .c with .cxx.
|
||||
</p>
|
||||
|
||||
|
||||
|
|
@ -1113,11 +1113,10 @@ Typesafe enums have their advantages over using plain integers in that they can
|
|||
However, there are limitations. For example, they cannot be used in switch statements and serialization is an issue.
|
||||
Please look at the following references for further information:
|
||||
|
||||
http://java.sun.com/developer/Books/shiftintojava/page1.html#replaceenums
|
||||
<a href="http://java.sun.com/developer/Books/shiftintojava/page1.html#replaceenums">Replace Enums with Classes</a> in <i>Effective Java Programming</i> on the Sun website,
|
||||
<a href="http://www.javaworld.com/javaworld/jw-07-1997/jw-07-enumerated.html">Create enumerated constants in Java</a> JavaWorld article,
|
||||
<a href="http://www.javaworld.com/javaworld/javatips/jw-javatip133.html">Java Tip 133: More on typesafe enums</a> and
|
||||
<a href="http://www.javaworld.com/javaworld/javatips/jw-javatip122.html">Java Tip 122: Beware of Java typesafe enumerations</a> JavaWorld tips.
|
||||
<a href="https://www.javaworld.com/article/2076970/create-enumerated-constants-in-java.html">Create enumerated constants in Java</a> JavaWorld article,
|
||||
<a href="https://www.javaworld.com/article/2077499/java-tip-133--more-on-typesafe-enums.html">Java Tip 133: More on typesafe enums</a> and
|
||||
<a href="https://www.javaworld.com/article/2077487/java-tip-122--beware-of-java-typesafe-enumerations.html">Java Tip 122: Beware of Java typesafe enumerations</a> JavaWorld tips.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
|
@ -2763,7 +2762,7 @@ The <tt>finalize()</tt> method calls <tt>delete()</tt> which frees any malloc'd
|
|||
The idea is for <tt>delete()</tt> to be called when you have finished with the C/C++ object.
|
||||
Ideally you need not call <tt>delete()</tt>, but rather leave it to the garbage collector to call it from the finalizer.
|
||||
When a program exits, the garbage collector does not guarantee to call all finalizers.
|
||||
An insight into the reasoning behind this can be obtained from <a href="http://www.hpl.hp.com/techreports/2002/HPL-2002-335.html">Hans Boehm's Destructors, Finalizers, and Synchronization</a> paper.
|
||||
An insight into the reasoning behind this can be obtained from <a href="https://www.hpl.hp.com/techreports/2002/HPL-2002-335.html">Hans Boehm's Destructors, Finalizers, and Synchronization</a> paper.
|
||||
Depending on what the finalizers do and which operating system you use, this may or may not be a problem.
|
||||
</p>
|
||||
|
||||
|
|
@ -2787,7 +2786,7 @@ Call the <tt>System.runFinalizersOnExit(true)</tt> or <tt>Runtime.getRuntime().r
|
|||
This method is inherently unsafe. It may result in finalizers being called on live objects while other threads are concurrently manipulating those objects, resulting in erratic behavior or deadlock.
|
||||
</i></div>
|
||||
<p>In many cases you will be lucky and find that it works, but it is not to be advocated.
|
||||
Have a look at <a href="http://www.oracle.com/technetwork/java/index.html">Java web site</a> and search for <tt>runFinalizersOnExit</tt>.
|
||||
Have a look at <a href="https://www.oracle.com/technetwork/java/index.html">Java web site</a> and search for <tt>runFinalizersOnExit</tt>.
|
||||
</p></li>
|
||||
|
||||
<li><p>
|
||||
|
|
@ -3629,7 +3628,7 @@ The %feature directive can be applied globally, to specific classes, and to spec
|
|||
// generate directors for all classes that have virtual methods
|
||||
%feature("director");
|
||||
|
||||
// generate directors for all virtual methods in class Foo
|
||||
// generate directors for the virtual methods in class Foo
|
||||
%feature("director") Foo;
|
||||
</pre>
|
||||
</div>
|
||||
|
|
@ -3647,7 +3646,7 @@ So for example,
|
|||
</div>
|
||||
|
||||
<p>
|
||||
will generate directors for all virtual methods of class Foo except bar().
|
||||
will generate directors for the virtual methods of class Foo except bar().
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
|
@ -3683,7 +3682,8 @@ The director classes store a pointer to their underlying Java proxy classes.
|
|||
<p>
|
||||
For simplicity let's ignore the <tt>Swig::Director</tt> class and refer to the original C++ class as the director's base class.
|
||||
By default, a director class extends all virtual methods in the inheritance chain of its base class (see the preceding section for how to modify this behavior).
|
||||
Thus all virtual method calls, whether they originate in C++ or in Java via proxy classes, eventually end up in at the implementation in the director class.
|
||||
Virtual methods that have a final specifier are unsurprisingly excluded.
|
||||
Thus the virtual method calls, whether they originate in C++ or in Java via proxy classes, eventually end up in at the implementation in the director class.
|
||||
The job of the director methods is to route these method calls to the appropriate place in the inheritance chain.
|
||||
By "appropriate place" we mean the method that would have been called if the C++ base class and its Java derived classes were seamlessly integrated.
|
||||
That seamless integration is exactly what the director classes provide, transparently skipping over all the messy JNI glue code that binds the two languages together.
|
||||
|
|
@ -5644,7 +5644,7 @@ This section describes how you can modify SWIG's default wrapping behavior
|
|||
for various C/C++ datatypes using the <tt>%typemap</tt> directive.
|
||||
You are advised to be familiar with the material in the "<a href="Typemaps.html#Typemaps">Typemaps</a>" chapter.
|
||||
While not absolutely essential knowledge, this section assumes some familiarity with the Java Native Interface (JNI).
|
||||
JNI documentation can be consulted either online at <a href="http://java.sun.com">Sun's Java web site</a> or from a good JNI book.
|
||||
JNI documentation can be consulted either online at <a href="https://www.oracle.com/technetwork/java/index.html">the Java web site</a> or from a good JNI book.
|
||||
The following two books are recommended:</p>
|
||||
|
||||
<ul>
|
||||
|
|
@ -6551,7 +6551,7 @@ As there can only be one "javacode" typemap per class, also consider using the
|
|||
and offers nearly identical functionality.
|
||||
</div>
|
||||
|
||||
<p><tt>%typemap(javadestruct, methodname="delete", methodmodifiers="public synchronized")</tt> <br></p>
|
||||
<p><tt>%typemap(javadestruct, methodname="delete", methodmodifiers="public synchronized", parameters="")</tt> <br></p>
|
||||
<div class="indent">
|
||||
destructor wrapper - the <tt>delete()</tt> method (proxy classes only),
|
||||
used for all proxy classes except those which have a base class
|
||||
|
|
@ -6562,9 +6562,10 @@ Note that the <tt>delete()</tt> method name is configurable and is specified by
|
|||
The method modifiers are also configurable via the <tt>methodmodifiers</tt> attribute.
|
||||
If a <tt>%javamethodmodifiers</tt> is attached to the class' destructor,
|
||||
it will be used in preference to the <tt>methodmodifiers</tt> typemap attribute for the class.
|
||||
The <tt>delete</tt> method's parameters declaration can be provided in the optional <tt>parameters</tt> typemap attribute.
|
||||
</div>
|
||||
|
||||
<p><tt>%typemap(javadestruct_derived, methodname="delete", methodmodifiers="public synchronized")</tt></p>
|
||||
<p><tt>%typemap(javadestruct_derived, methodname="delete", methodmodifiers="public synchronized", parameters="")</tt></p>
|
||||
<div class="indent">
|
||||
destructor wrapper - the <tt>delete()</tt> method (proxy classes only),
|
||||
same as "javadestruct" but only used for derived proxy classes
|
||||
|
|
@ -6575,6 +6576,7 @@ Note that the <tt>delete()</tt> method name is configurable and is specified by
|
|||
The method modifiers are also configurable via the <tt>methodmodifiers</tt> attribute.
|
||||
If a <tt>%javamethodmodifiers</tt> is attached to the class' destructor,
|
||||
it will be used in preference to the <tt>methodmodifiers</tt> typemap attribute for the class.
|
||||
The <tt>delete</tt> method's parameters declaration can be provided in the optional <tt>parameters</tt> typemap attribute.
|
||||
</div>
|
||||
|
||||
<p><tt>%typemap(javaimports)</tt></p>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css" href="./style.css">
|
||||
<link rel="stylesheet" type="text/css" href="style.css">
|
||||
<title></title>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
|
|
@ -56,10 +56,10 @@
|
|||
|
||||
|
||||
<p>Javascript is a prototype-based scripting language that is dynamic, weakly typed and has first-class functions. Its arguably the most popular language for web development.
|
||||
Javascript has gone beyond being a browser-based scripting language and with <a href="http://nodejs.org">node.js</a>, it is also used as a backend development language.</p>
|
||||
Javascript has gone beyond being a browser-based scripting language and with <a href="https://nodejs.org">node.js</a>, it is also used as a backend development language.</p>
|
||||
<p>Native Javascript extensions can be used for applications that embed a web-browser view or that embed a Javascript engine (such as <em>node.js</em>). Extending a general purpose web-browser is not possible as this would be a severe security issue.</p>
|
||||
<p>SWIG Javascript currently supports <strong>JavascriptCore</strong>, the Javascript engine used by <code>Safari/Webkit</code>, and <a href="https://developers.google.com/v8"><strong>v8</strong></a>, which is used by <code>Chromium</code> and <code>node.js</code>.</p>
|
||||
<p><a href="http://www.webkit.org/">WebKit</a> is a modern browser implementation available as open-source which can be embedded into an application.
|
||||
<p>SWIG Javascript currently supports <strong>JavascriptCore</strong>, the Javascript engine used by <code>Safari/Webkit</code>, and <a href="https://v8.dev/"><strong>v8</strong></a>, which is used by <code>Chromium</code> and <code>node.js</code>.</p>
|
||||
<p><a href="https://webkit.org/">WebKit</a> is a modern browser implementation available as open-source which can be embedded into an application.
|
||||
With <a href="https://github.com/rogerwang/node-webkit">node-webkit</a> there is a platform which uses Google's <code>Chromium</code> as Web-Browser widget and <code>node.js</code> for javascript extensions.
|
||||
</p>
|
||||
|
||||
|
|
@ -289,7 +289,7 @@ extern bool example_initialize(JSGlobalContextRef context, JSObjectRef* exports)
|
|||
<H4><a name="Javascript_gtk">27.3.2.2 GTK</a></H4>
|
||||
|
||||
|
||||
<p>There is general information about programming GTK at <a href="https://developer.gnome.org/gtk2/">GTK documentation</a> and in the <a href="https://developer.gnome.org/gtk-tutorial">GTK tutorial</a>, and for Webkit there is a <a href="http://webkitgtk.org/reference/webkitgtk/stable/index.html">Webkit GTK+ API Reference</a>.</p>
|
||||
<p>There is general information about programming GTK at <a href="https://developer.gnome.org/gtk2/">GTK documentation</a> and in the <a href="https://developer.gnome.org/gtk-tutorial/">GTK tutorial</a>, and for Webkit there is a <a href="http://webkitgtk.org/reference/webkitgtk/stable/index.html">Webkit GTK+ API Reference</a>.</p>
|
||||
<p>An integration of a native extension 'example' would look like this:</p>
|
||||
<div class="code">
|
||||
<pre>
|
||||
|
|
@ -604,7 +604,7 @@ at ReadStream.EventEmitter.emit (events.js:98:17)
|
|||
at emitKey (readline.js:1095:12)</pre>
|
||||
</div>
|
||||
<p>
|
||||
<b>Note</b>: In ECMAScript 5 there is no concept for classes. Instead each function can be used as a constructor function which is executed by the 'new' operator. Furthermore, during construction the key property <code>prototype</code> of the constructor function is used to attach a prototype instance to the created object. A prototype is essentially an object itself that is the first-class delegate of a class used whenever the access to a property of an object fails. The very same prototype instance is shared among all instances of one type. Prototypal inheritance is explained in more detail on in <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Inheritance_and_the_prototype_chain">Inheritance and the prototype chain</a>, for instance.
|
||||
<b>Note</b>: In ECMAScript 5 there is no concept for classes. Instead each function can be used as a constructor function which is executed by the 'new' operator. Furthermore, during construction the key property <code>prototype</code> of the constructor function is used to attach a prototype instance to the created object. A prototype is essentially an object itself that is the first-class delegate of a class used whenever the access to a property of an object fails. The very same prototype instance is shared among all instances of one type. Prototypal inheritance is explained in more detail on in <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Inheritance_and_the_prototype_chain">Inheritance and the prototype chain</a>, for instance.
|
||||
</p>
|
||||
|
||||
<H2><a name="Javascript_implementation">27.5 Implementation</a></H2>
|
||||
|
|
|
|||
|
|
@ -1365,7 +1365,7 @@ to accomplish this in SWIG. This library provides support for a few common tech
|
|||
</li>
|
||||
|
||||
<li>If used in C++, this library uses <tt>new</tt> and <tt>delete []</tt> for memory
|
||||
allocation. If using ANSI C, the library uses <tt>malloc()</tt> and <tt>free()</tt>.
|
||||
allocation. If using C, the library uses <tt>malloc()</tt> and <tt>free()</tt>.
|
||||
</li>
|
||||
|
||||
<li>Rather than manipulating <tt>char *</tt> directly, you might consider using a special string
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@
|
|||
|
||||
|
||||
<p>
|
||||
Lua is an extension programming language designed to support general procedural programming with data description facilities. It also offers good support for object-oriented programming, functional programming, and data-driven programming. Lua is intended to be used as a powerful, light-weight configuration language for any program that needs one. Lua is implemented as a library, written in clean C (that is, in the common subset of ANSI C and C++). It's also a <em>really</em> tiny language, less than 6000 lines of code, which compiles to <100 kilobytes of binary code. It can be found at <a href="http://www.lua.org">http://www.lua.org</a>
|
||||
Lua is an extension programming language designed to support general procedural programming with data description facilities. It also offers good support for object-oriented programming, functional programming, and data-driven programming. Lua is intended to be used as a powerful, light-weight configuration language for any program that needs one. Lua is implemented as a library, written in clean C (that is, in the common subset of ISO C and C++). It's also a <em>really</em> tiny language, less than 6000 lines of code, which compiles to <100 kilobytes of binary code. It can be found at <a href="http://www.lua.org">http://www.lua.org</a>
|
||||
</p>
|
||||
<p>
|
||||
eLua stands for Embedded Lua (can be thought of as a flavor of Lua) and offers the full implementation of the Lua programming language to the embedded world, extending it with specific features for efficient and portable software embedded development. eLua runs on smaller devices like microcontrollers and provides the full features of the regular Lua desktop version. More information on eLua can be found here: <a href="http://www.eluaproject.net">http://www.eluaproject.net</a>
|
||||
|
|
|
|||
|
|
@ -89,3 +89,9 @@ linkchecker2:
|
|||
cp *.png linkchecker-tmp
|
||||
(cd linkchecker-tmp && linkchecker --config=../linkchecker.config -F text --no-warnings SWIGDocumentation.html)
|
||||
|
||||
# Simple check for relative links (there shouldn't be any), they don't translate properly creating the .pdf doc
|
||||
# with wkhtmltopdf. For example, href="SWIG.html" needs to be href="SWIG.html#SWIG"
|
||||
linkchecker3:
|
||||
@echo "The following list should just contain SWIGDocumentation.html and SWIGDocumentation.pdf,"
|
||||
@echo "as all links should have an anchor (with a #) or be a full url beginning http."
|
||||
grep 'href="' *.html | sed -e 's/.*href="\(.*\)">.*$$/\1/' | grep -v "#" | grep -v "^http" | grep -v "^style.css"
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ Some points of interest:
|
|||
|
||||
|
||||
<p>
|
||||
See the <a href="http://docs.racket-lang.org/inside/index.html">C API</a> for more description of using the mechanism for adding extensions. The main documentation is <a href="http://docs.racket-lang.org/">here</a>.
|
||||
See the <a href="https://docs.racket-lang.org/inside/index.html">C API</a> for more description of using the mechanism for adding extensions. The main documentation is <a href="https://docs.racket-lang.org/">here</a>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
|
|
|||
|
|
@ -3070,7 +3070,7 @@ globally, to specific classes, and to specific methods, like this:
|
|||
// generate directors for all classes that have virtual methods
|
||||
%feature("director");
|
||||
|
||||
// generate directors for all virtual methods in class Foo
|
||||
// generate directors for the virtual methods in class Foo
|
||||
%feature("director") Foo;
|
||||
</pre>
|
||||
</div>
|
||||
|
|
@ -3088,7 +3088,7 @@ directors for specific classes or methods. So for example,
|
|||
</div>
|
||||
|
||||
<p>
|
||||
will generate directors for all virtual methods of class Foo except
|
||||
will generate directors for the virtual methods of class Foo except
|
||||
bar().
|
||||
</p>
|
||||
|
||||
|
|
@ -3153,7 +3153,8 @@ For simplicity let's ignore the <tt>Swig::Director</tt> class and refer to the
|
|||
original C++ class as the director's base class. By default, a director
|
||||
class extends all virtual methods in the inheritance chain of its base
|
||||
class (see the preceding section for how to modify this behavior).
|
||||
Thus all virtual method calls, whether they originate in C++ or in
|
||||
Virtual methods that have a final specifier are unsurprisingly excluded.
|
||||
Thus the virtual method calls, whether they originate in C++ or in
|
||||
Perl via proxy classes, eventually end up in at the implementation in
|
||||
the director class. The job of the director methods is to route these
|
||||
method calls to the appropriate place in the inheritance chain. By
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue