[Scummvm-cvs-logs] SF.net SVN: scummvm:[43694] scummvm/trunk/engines/m4/script.h

lordhoto at users.sourceforge.net lordhoto at users.sourceforge.net
Mon Aug 24 14:27:25 CEST 2009


Revision: 43694
          http://scummvm.svn.sourceforge.net/scummvm/?rev=43694&view=rev
Author:   lordhoto
Date:     2009-08-24 12:27:25 +0000 (Mon, 24 Aug 2009)

Log Message:
-----------
Add comment why the syntax for ScriptDataCache::load was changed.

Modified Paths:
--------------
    scummvm/trunk/engines/m4/script.h

Modified: scummvm/trunk/engines/m4/script.h
===================================================================
--- scummvm/trunk/engines/m4/script.h	2009-08-24 12:24:35 UTC (rev 43693)
+++ scummvm/trunk/engines/m4/script.h	2009-08-24 12:27:25 UTC (rev 43694)
@@ -119,6 +119,15 @@
 	~ScriptDataCache() {
 		clear();
 	}
+
+	// WORKAROUND: The old prototype for this function was:
+	// template<class T> T *load(Common::File *fd, uint32 ofs);
+	// that caused a parser error in g++ 3.3.6 used by our
+	// "motoezx" target of our buildbot. The actual parser
+	// error happended, when calling the function like this:
+	// "T *result = _dataCache->load<T>(_scriptFile, _data[value.value]->offset);"
+	// in ScriptInterpreter::toData. To work around this
+	// we moved the return value as parameter instead.
 	template<class T>
 	void load(Common::File *fd, uint32 ofs, T *&item) {
 		if (_cache.contains(ofs)) {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list