Commit 78d19475 authored by Tom Niget's avatar Tom Niget

Fix async call detection for stdlib context

parent e1cd0021
......@@ -98,7 +98,7 @@ class ScoperExprVisitor(ScoperVisitor):
node.is_await = True
actual = actual.return_type.resolve()
if isinstance(actual, Promise) and actual.kind == PromiseKind.FORKED \
if self.scope.function and isinstance(actual, Promise) and actual.kind == PromiseKind.FORKED \
and isinstance(fty := self.scope.function.obj_type.return_type, Promise):
fty.kind = PromiseKind.JOIN
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment