returning an array argument
情報
この質問は閉じられています。 編集または回答するには再度開いてください。
古いコメントを表示
I am returning a double array, inst_array, from a function:
function [inst_array, pass ] = ....
In the called function, the return argument looks correct, I explicitly assign it.
But If I stop the debugger just after returning, the returning variable holds the incorrect double values. It is dimensioned correctly, and some values are incorrect.
1 件のコメント
the cyclist
2012 年 2 月 16 日
Are you able to distill this into a small problem that you can post here? You're not really giving us much to go on. :-)
回答 (1 件)
John Lofgren
2012 年 2 月 16 日
0 投票
2 件のコメント
Walter Roberson
2012 年 2 月 16 日
Absolutely definitely Yes.
function foo = bar()
foo = magic(5);
end
James Tursa
2012 年 2 月 16 日
Yes. MATLAB can return any variable, including an array.
この質問は閉じられています。
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!