Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mlz
libcerf
Commits
fbd6126a
Commit
fbd6126a
authored
Jun 18, 2021
by
Wuttke, Joachim
Browse files
Try complex.i: compiles, doesn't work
parent
1095049c
Pipeline
#39428
failed with stage
in 12 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
python/libcerf.i
View file @
fbd6126a
%
module
"libcerf"
/* Convert from Python --> C */
%
typemap
(
in
)
_cerf_cmplx
{
$
1
=
((
Py_complex
*
)
$
input
)
->
real
+
_Complex_I
*
((
Py_complex
*
)
$
input
)
->
imag
;
}
/* Convert from C --> Python */
%
typemap
(
out
)
int
{
$
result
=
Py_complex
(
creal
(
$
1
),
cimag
(
$
1
))
;
}
%
{
#
include
"lib/cerf.h"
%
}
%
include
<
complex
.
i
>
%
include
"lib/cerf.h"
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment