Skip to content

Can't access get findEnemies of that type: undefined #163

Description

@nwinter

In Ace of Coders, this code errors out:

while True:
    outer()
def outer():
    enemies = hero.findEnemies()

screenshot 2016-05-22 13 47 04

If I def outer() before the while True:, it works.

Is JS-style hoisting not working? If so, can we make it work, or can we get a better error message?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions