Hi there,
I'd like to propose a small change to the Python bindings: making `Filter.Compile()` return the extracted literal atoms instead of `None`.
The C++ `FilteredRE2::Compile()` currently
extracts atoms that must appear for any pattern to match. These are useful for building secondary indexes (bloom filters, n-gram indexes) to prefilter candidates before running expensive regex matches.
The current return value is always None, so `if f.Compile():` is always false. Returning a list would make this truthy when atoms are extracted, which would arguably be more useful than the current return value. The only breaking case would be explicit `if result is None:` checks, which seems unlikely given the undocumented None return.
Questions:
1. Is this the right approach, or would a separate `GetAtoms()` method be preferred?
2. Any concerns about storing atoms as a member variable?
Happy to send a PR if this sounds reasonable.
Thanks,
Akshay