Package patterns
This branch adds support for package patterns. It consists of three parts:
-
A parser for a reduced aptitude pattern syntax which builds parse trees -
A class that transforms a parse tree into an APT::CacheFilter::Matcher
-
Various new PackageMatcher
subclasses
Note how the parser uses exception handling to simplify the code. It's not always super easy to follow, but it's much safer than generating matchers with an invalid object inside of them. In the only public function, we catch any exception from the parser and turn it into an _error
error.
Edited by Julian Andres Klode