Make as_op instances pickleable.
Add a test for the pickle functionality.
Merge pull request #2021 from abergeron/pickle_as_op

Make as_op instances pickleable.