Use explicit logic for pruning