allow search classes to use proc as search target

I think it might help in cases like #17 or #20.

what do you think about it?