patch by Kevin Smith to emit directors when %feature("director") is specified for a class with no virtual methods, but a virtual destructor
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5905 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
ae8e4a8a6c
commit
3ff1711d49
2 changed files with 6 additions and 1 deletions
|
|
@ -1,6 +1,11 @@
|
||||||
Version 1.3.22 (in progress)
|
Version 1.3.22 (in progress)
|
||||||
==================================
|
==================================
|
||||||
|
|
||||||
|
05/12/2004: wsfulton
|
||||||
|
Patch for emitting directors when %feature("director") specified
|
||||||
|
for a class with no virtual methods, but does have a virtual destructor.
|
||||||
|
Submitted by Kevin Smith.
|
||||||
|
|
||||||
05/06/2004: mkoeppe (Matthias Koeppe)
|
05/06/2004: mkoeppe (Matthias Koeppe)
|
||||||
New SWIG runtime function SWIG_TypePrettyName, which
|
New SWIG runtime function SWIG_TypePrettyName, which
|
||||||
returns an unmangled type name for a swig_type_info
|
returns an unmangled type name for a swig_type_info
|
||||||
|
|
|
||||||
|
|
@ -1708,7 +1708,7 @@ int Language::classDirector(Node *n) {
|
||||||
Hash* vtable = NewHash();
|
Hash* vtable = NewHash();
|
||||||
int virtual_destructor = 0;
|
int virtual_destructor = 0;
|
||||||
unrollVirtualMethods(n, n, vtable, 0, virtual_destructor);
|
unrollVirtualMethods(n, n, vtable, 0, virtual_destructor);
|
||||||
if (Len(vtable) > 0) {
|
if (virtual_destructor || Len(vtable) > 0) {
|
||||||
if (!virtual_destructor) {
|
if (!virtual_destructor) {
|
||||||
String *classtype = Getattr(n, "classtype");
|
String *classtype = Getattr(n, "classtype");
|
||||||
Swig_warning(WARN_LANG_DIRECTOR_VDESTRUCT, input_file, line_number,
|
Swig_warning(WARN_LANG_DIRECTOR_VDESTRUCT, input_file, line_number,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue