Allow external operator use

Based on work by @tophsic, DRYed up and refined a bit to not use static variables.

See #16