Opened 15 years ago
Last modified 15 years ago
#1158 closed defect (fixed)
mismatch of return values (return + pointer) of extrenal function and result structure
Reported by: | Henning Kiel | Owned by: | Henning Kiel |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Version: | ||
Keywords: | Cc: | Henning Kiel, Martin Sjölund |
Description
external C function "fexttest" called this way:
... algorithm if HallSignal <> pre(HallSignal) then (Check, BBR) := fexttest(omega, HallPos, table); ...
function fexttest input Real omega; input Integer Pos; input demoPack_Data PPP; output Integer rv; output Integer outx; external "C" rv = exttest(omega, Pos, outx, PPP) annotation(Library = "exttest.o", Include = "#include \"exttest.h\""); end fexttest;
The prototype and function call are done properly. But when copied into the result structure, the order is mixed up:
rv_ext = exttest(omega_ext, Position_ext, &outx_ext, PPP_ext); out.targ1 = (modelica_integer)outx_ext; out.targ2 = (modelica_integer)rv_ext;
Note:
See TracTickets
for help on using tickets.