hi Denis,<br><br><div class="gmail_quote">On Mon, Jul 6, 2009 at 10:25 AM, <span dir="ltr"><<a href="mailto:dkasak13@users.sourceforge.net">dkasak13@users.sourceforge.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Revision: 42183<br>
<a href="http://scummvm.svn.sourceforge.net/scummvm/?rev=42183&view=rev" target="_blank">http://scummvm.svn.sourceforge.net/scummvm/?rev=42183&view=rev</a><br>
Author: dkasak13<br>
Date: 2009-07-06 17:25:34 +0000 (Mon, 06 Jul 2009)<br>
<br>
Log Message:<br>
-----------<br>
Implemented GPL operators.<br>
<br>
Modified Paths:<br>
--------------<br>
scummvm/branches/gsoc2009-draci/engines/draci/script.cpp<br>
scummvm/branches/gsoc2009-draci/engines/draci/script.h<br>
</blockquote><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><br> typedef void (Script::* GPLHandler)(Common::Queue<int> &);<br>
+typedef int (Script::* GPLOperatorHandler)(int, int);<br></blockquote><div><br></div><div>completely unimportant and optional remark: you don't need these callbacks to be normal methods of the class Script (i.e., methods that need a pointer to an instance), but having them static methods or even just static global functions should be enough. this way you would emphasize that they are just first-order functions without any access to the state, i.e. that they only compute a mathematical function of their arguments. </div>
</div><br>-- <br>Robert Špalek <<a href="mailto:rspalek@gmail.com">rspalek@gmail.com</a>><br>