Jump to content
  • Advertisement
Sign in to follow this  
abrken

assert in asCCompiler::Dereference

This topic is 4889 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, This is an assert that I felt into. First, I felt into this assert because my script plugin wasn't loading and so, some class weren't referenced. Loading a script (that was using those class of course !), I get an assert failure on an equal statement. this assert occurs in file as_compiler.cpp in function asCCompiler::Dereference in the last else that raised an assert. The type->dataType.GetSizeInMemoryDWords() returned 4. This is the script that is causing the assert :
	CStringArray	csaCommunicators;
	CString 	csBornetteId,
						csBornettes0,
						csBornettes1;
	int				iLoop;

	for (iLoop = 0; iLoop < barBornettes.GetSize(); iLoop++) {
		CBornette *pBornette = g_BornetteGestionnaire.GetBornette(barBornettes.GetAt(iLoop));
	
		if (pBornette != 0) {
			if (pBornette->GetCommunicatorId() == csaCommunicators.GetAt(0)) {
			}
		}
	}

the assert happen at the "if (pBornette->Get ...." Note that csaCommunicator.GetAt(0) return a CString (declared as CString GetAt(int) ). Also note that angelscript is telling this at compilation time :
MaNouvellePage_MOUSE_0 (42, 3) : Error   : Identifier 'CBornette' is not a data type
MaNouvellePage_MOUSE_0 (42, 26) : Error   : 'g_BornetteGestionnaire' is not declared
MaNouvellePage_MOUSE_0 (42, 48) : Error   : Illegal operation on 'int&'
MaNouvellePage_MOUSE_0 (42, 26) : Error   : Can't implicitly convert from 'const int' to 'int*'.
MaNouvellePage_MOUSE_0 (45, 17) : Error   : Illegal operation on 'int*&'
//
// The exception is then raised and ignored, the compilation continue
//
MaNouvellePage_MOUSE_0 (45, 39) : Error   : Both expressions must have the same type

Of course, if the plugin is correctly loaded, the assert dissepear. I have made the test first in 1.10.1b then I have test it with 1.10.1c with the same result. Thank's for any reply. AbrKen.

Share this post


Link to post
Share on other sites
Advertisement
I'd just like to let you know that I didn't forget about this bug. I've now found and fixed it.

I will upload version 1.10.1d as soon as possible with this bug fix as well as others found during the development of 2.0.0. Some of the issues found during the development can't be fixed and will be noted as known issues (they are minor and can be worked around). It will all be available on the site soon.

Regards,
Andreas

Share this post


Link to post
Share on other sites
Very good news !

Actually I'm ill and not working on computer anymore but soon I'll be back to test 1.10.1d next week.

It's good to see that your'r supporting so well the 1.x version of angelscript.

Regards,
AbrKen.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!