Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jl.mexn has multi-output, but jl.call does not #49

Open
standarddeviant opened this issue Jul 22, 2017 · 1 comment
Open

jl.mexn has multi-output, but jl.call does not #49

standarddeviant opened this issue Jul 22, 2017 · 1 comment

Comments

@standarddeviant
Copy link
Contributor

standarddeviant commented Jul 22, 2017

This is related to #48 because I can't figure out how to get multiple outputs from a julia function.

Again, with this as the example:

# nargoutTest.jl
function nargoutTest(a,b)
  @show a, b
  return "outp1", "outpTWO"
end

I can't figure out how to cleanly get both outputs. I tried

jl.include('nargoutTest.jl')
[a,b] = jl.mexn(2,'nargoutTest',3,2)

That crashes MATLAB 2016b, Win10, x86-64 consistently. Given that mexn isn't in the README.md, I think I might be misusing it...

But at the moment, jl.call has no options for multiple outputs. Is this functionality a technical limitation, or something straightforward that just needs to be implemented?

@standarddeviant
Copy link
Contributor Author

I think I see a solution to this after looking at the code, but am learning how mexjulia passes data around and how varargout works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant