Repair bad zero-indexed final matches. fixes #754