VS2012 build fix

VS2013 was ok, but VS2012 said "active pattern is not a function".