Handle typemap argument without a value

This now gives an error, previously SWIG segfaulted.

Fixes #891
This commit is contained in:
Olly Betts 2022-03-02 15:53:51 +13:00
commit aa24e6b22b
4 changed files with 29 additions and 10 deletions

View file

@ -0,0 +1,6 @@
%module xxx
%typemap(in, numinputs=1, foo) int ""
/* SWIG segfaulted trying to use the above typemap in SWIG < 4.1.0. */
void func(int arg);

View file

@ -0,0 +1 @@
swig_typemap_missing_value.i:3: Error: %typemap argument 'foo' is missing value