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

Reqest: allow for a pipe at end of map do block #177

Closed
fredcallaway opened this issue Dec 10, 2020 · 2 comments
Closed

Reqest: allow for a pipe at end of map do block #177

fredcallaway opened this issue Dec 10, 2020 · 2 comments

Comments

@fredcallaway
Copy link
Contributor

I often have a structures like this in my code

results = map(jobs) do job
    job => work(job)
end |> Dict

If I try to throw a @showprogress on this, I get an error " ArgumentError: Final argument to @showprogress must be a for loop, comprehension, map, or pmap". This can of course be fixed with a temporary variable, but if it's an easy fix to parse the do block here correctly, it would be more convenient. More importantly, it would prevent confusion from aa somewhat mysterious error message.

@timholy
Copy link
Owner

timholy commented Dec 11, 2020

If that can be made to work without breaking existing functionality, I'd be happy to have it. Want to submit a PR?

@timholy
Copy link
Owner

timholy commented Dec 15, 2020

Closed by #179. (Pro tip: had you written "fixes #177" or "closes #177" instead of "addresses #177", this would have happened automatically.)

@timholy timholy closed this as completed Dec 15, 2020
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

2 participants