Add caching to pattern enumeration

Inventory._hosts_in_unenumerated_pattern()

Was TODO: cache this logic so if called a second time the result is not
recalculated
Merge pull request #4429 from sergevanginderachter/cache_pattern_enumeration

Add caching to pattern enumeration