opfunc not defined in this scope.

This should do the same thing as was intended, I hope.