Fixes #26 - remove unused parameter

Remove unused parameter from OpFactory and methods
currently accessing it.
Properly class-cast inside CmpOp

There where some instances where class casting
was throwing exceptions. This should prevent
those issues from happening when a primative
Integer comes down the pipe - now with unit tests!
Merge pull request #27 from strazzere/master

Properly class-cast inside CmpOp, fix #26