diff options
author | Eric Blossom | 2010-10-23 20:59:54 -0700 |
---|---|---|
committer | Eric Blossom | 2010-11-10 12:13:53 -0800 |
commit | 27d1af7c7511addac638856bc2ffd3cda5e7ab0c (patch) | |
tree | 902126983b69a4d17289b49faa7c938c0179b601 /gnuradio-core/src/lib | |
parent | 5939ce6971607b83b33c2ac0ede627a83670113a (diff) | |
download | gnuradio-27d1af7c7511addac638856bc2ffd3cda5e7ab0c.tar.gz gnuradio-27d1af7c7511addac638856bc2ffd3cda5e7ab0c.tar.bz2 gnuradio-27d1af7c7511addac638856bc2ffd3cda5e7ab0c.zip |
Add %typecheck for complex.
Fixes problem with moving-average-cc.
Diffstat (limited to 'gnuradio-core/src/lib')
-rw-r--r-- | gnuradio-core/src/lib/swig/guile/std_complex.i | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gnuradio-core/src/lib/swig/guile/std_complex.i b/gnuradio-core/src/lib/swig/guile/std_complex.i index cafcfeae3..2a5c72aa2 100644 --- a/gnuradio-core/src/lib/swig/guile/std_complex.i +++ b/gnuradio-core/src/lib/swig/guile/std_complex.i @@ -28,3 +28,10 @@ %typemaps_primitive(%checkcode(CPLXDBL), std::complex<double>); %typemaps_primitive(%checkcode(CPLXFLT), std::complex<float>); + +%typecheck(SWIG_TYPECHECK_COMPLEX) + std::complex<float>, std::complex<double>, + const std::complex<float> &, const std::complex<double> & +{ + $1 = scm_is_complex($input) ? 1 : 0; +} |