Skip to content

Commit

Permalink
Tests are back too
Browse files Browse the repository at this point in the history
  • Loading branch information
alexp-sssup committed Aug 8, 2010
1 parent e30ab81 commit 8020107
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions asobjects.h
Expand Up @@ -217,14 +217,22 @@ CLASSBUILDABLE(IFunction);
{
if(!bound)
{
//If binding with null we are not a class method
//Generate a copy
IFunction* ret=clone();
IFunction* ret=NULL;
if(c==NULL)
{
//If binding with null we are generated from newFunction, don't copy
ret=this;
}
else
{
//Generate a copy
ret=clone();
}
ret->bound=true;
ret->closure_this=c;
if(c)
c->incRef();
//ret->closure_level=level;
ret->closure_level=level;
//std::cout << "Binding " << ret << std::endl;
return ret;
}
Expand Down

0 comments on commit 8020107

Please sign in to comment.