onCompile now compatbile with Nette\Object

See https://github.com/Kdyby/Events/issues/41