-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Tcpsocket and @async problem #10589
Comments
So only available on v0.4 but not v0.3+ ? |
Not currently, no. |
There have been a bunch of intermittent TypeErrors and other CI instabilities that seem to be related (or uncovered?) by that one so I would vote against backporting that change. |
So how do I get access to variables computed inside an @async begin ... end ? |
Anyway, the problem here is the extra
|
So is there any bug? Please reopen if this is not the same as #10405. I don't see why I can't use
|
Well, it's hard to say. It's basically working as expected within the semantics of the language, because inner function capture locals:
with the inherent consequence that if you use the local (in the task) before it's assigned you get an error. So everything is working as intended, though it may be surprising. |
I guess the macro could recognize variables that are only assigned, but not read before? @JeffBezanson does that seem reasonable? |
It works when I use different variable names and not use the same variable name in
|
dup of #2669 |
Error: socket is undefined
I get the error that socket is undefined. This works in REPL but not when the program is executed from inside a function f()
Note: Julia v 0.36
The text was updated successfully, but these errors were encountered: