Adding support for this feature required a change to the private function selector-type: the check for :key-values was originally vector? and ensuring there were an even number of elements. This would obviously conflict with an even number of exceptions. So I added a third requirement: every other element must be a keyword for it to be a :key-values. This then left room for a new selector type: :class-names which checks if every element of the vector is a class.
To pair with that, I added a new selector-matches? method that checks that the given object is an instance of at least one of the elements in the vector of exception classes.
Addresses issue/request of ticket #33.
Adding support for this feature required a change to the private function
selector-type
: the check for:key-values
was originallyvector?
and ensuring there were an even number of elements. This would obviously conflict with an even number of exceptions. So I added a third requirement: every other element must be a keyword for it to be a:key-values
. This then left room for a new selector type::class-names
which checks if every element of the vector is a class.To pair with that, I added a new
selector-matches?
method that checks that the given object is an instance of at least one of the elements in the vector of exception classes.