🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Assertion failure in compiler when using delegate

Started by
1 comment, last by WitchLord 9 years, 2 months ago

The following script triggers an assertion failure in as_compiler.cpp on line 1156:


funcdef void Callback();

class Foo
{
	void Bar()
	{
	}
}

void test()
{
	Callback@ cb = Callback( Foo().Bar );
}

If assertions are disabled, this results in the temporary object leaking. Instancing the object before creating the delegate works around the issue.

Tested using the latest SVN library source.

Advertisement

Thanks for reporting this.

I'll investigate and have it fixed as soon as possible.

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

I've fixed this in revision 2160.

Regards,

Andreas

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

This topic is closed to new replies.

Advertisement