mirror of
https://github.com/zed-industries/zed.git
synced 2026-11-19 06:59:22 +01:00
042e0406d3
## Summary I think we are getting closer to fully making `PathStyle` a mirrored, cross-platform counterpart to `Path` on top of #65782. Before the final step — a separate change focused solely on the `join_path`-related methods — this PR clears up the remaining odds and ends and removes the leftover helpers from the `path` crate. The `normalize_path` function is moved to `crates/util/src/paths.rs`, as it has no cross-platform behavior, so `util` is a more appropriate home for it. `PathStyle::split()` is removed. Its functionality can be replaced by `PathStyle::file_name()` plus stripping the file name from the original path, and since there is only one caller, the migration is straightforward. ## Testing Mostly a refactor. For the only caller of `PathStyle::split()`, the multi-buffer header, I manually tested that the header still renders the file name and parent directory correctly. ## Self-review - [x] I've reviewed my diff for quality, security, reliability, and performance. - [x] UI changes follow the [checklist](https://zed.dev/docs/development/ui-checklist). - [x] Tests cover the new or changed behavior. Release Notes: - N/A