Previously, I described a version of lazy matching with 2-byte lookahead ? instead of a just checking for a next byte for a longer match, as GZIP does with ?9? switch, we also check second byte for a longer match. If we checking from second byte, we probably should increase our threshold for dropping a match ? we will drop a match if we find, for example, a longer match than current match length plus one.
OK, but what if we have found a longer match at the first byte, but after current match us may find even longer match? And here we may use an advanced Lazy Matching ? we keep the sum of current match length and length of the followed after that match. If at first, second, or longer distance we will find a longer match compared to that sum, we drop current match easily. This scheme can be regarded as a simplified or restricted Flexible Parsing.
I think I will add such parsing to the BALZ v1.06!