Problem with something..

Started by
3 comments, last by Mkk 20 years ago
I have static member variable: static Block *firstBlock; And method:

GLvoid Block::DeleteAll()
{
	Block *thisBlock;
	Block *deleteBlock;

	if (firstBlock == NULL)
		return;

	thisBlock = firsBlock; // This line gives those errors..

      // Without line above everything works ok.


	while (thisBlock != NULL)
	{

	}
}
(Both belongs to the same class) when I try to put firstBlock to the thisBlock, compiler will give me errors: C:\OPENGL PROJECT1\classBlock.cpp(61) : error C2065: ''firsBlock'' : undeclared identifier C:\OPENGL PROJECT1\classBlock.cpp(61) : error C2440: ''='' : cannot convert from ''int'' to ''class Block *'' Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast Error executing cl.exe. But without that line everything works ok so what could be the problem?
Advertisement
The problem could be a typo. Read the problem line carefully
LOL. LOOOOLOLOLOLOL.

Thanks! *runs away*
Great topic title btw


The Monkey is back !
Hehe, yes, it really looks like the last piece of my brains have just started to melt up.

Just in time I couldn´t figure out anything better (what can you except if I can´t even find variable typo myself? ). Sorry.



This topic is closed to new replies.

Advertisement