lambda fails if it references undefined types #245

Open
ribrdb opened this Issue Feb 10, 2014 · 0 comments

Projects

None yet

1 participant

@ribrdb
Collaborator
ribrdb commented Feb 10, 2014
interface FooInterface
  def foo:Foo
  end
end

def fooMaker
  lambda(FooInterface) {nil}
end

class Foo
end

This produces

ERROR: Cannot find class :error
  lambda(FooInterface) {nil}
                       ^^^^^

It seems to work with a block:

interface FooInterface
  def foo:Foo
  end
end

def useFoo(foo:FooInterface)
  foo.foo
end

def makeAndUseFoo
  useFoo do
    nil
  end
end

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