Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools: prefer filter to remove empty strings
Ref: #23585 (comment) Python's `list.remove` will throw if the element is not found and also it removes only the first occurrence. This patch replaces the use of `list.remove` with a `filter` which solves both of the above mentioned problems. PR-URL: #23727 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rod Vagg <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Matheus Marchini <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]>
- Loading branch information