mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-25 18:03:37 +08:00
86803e4442
This makes it so expand_intermediate_segment knows about the case where it's last, only followed by a "/". When it is, it can do without the file_id for finding links (we don't resolve the files we get here), which allows us to remove a stat() call. This speeds up the case of `...*/` by quite a bit. If that last component was a directory with 1000 subdirectories we could skip 1000 stat calls! One slight weirdness: We refuse to add links to directories that we already visited, even if they are the last component and we don't actually follow them. That means we can't do the fast path here either, but we do know if something is a link (if we get d_type), so it still works in common cases. |
||
---|---|---|
.. | ||
src | ||
widestring-suffix | ||
build.rs |