Pass options object into scanner

This is tested by making sure that the options used by the
PlaceholderParser are propagated to the scanner.
Scanner is such a bottle neck that using `this.foo` makes things slow. I could do another pass trying to make this fast without "global" state.