rust/src/libstd/sys/windows
bors b298607864 Auto merge of #47956 - retep998:is-nibbles, r=BurntSushi
This is the ideal FileType on Windows. You may not like it, but this is what peak performance looks like.

Theoretically this would fix https://github.com/rust-lang/rust/issues/46484

The current iteration of this PR should not cause existing code to break, but instead merely improves handling around reparse points. Specifically...

* Reparse points are considered to be symbolic links if they have the name surrogate bit set. Name surrogates are reparse points that effectively act like symbolic links, redirecting you to a different directory/file. By checking for this bit instead of specific tags, we become much more general in our handling of reparse points, including those added by third parties.
* If something is a reparse point but does not have the name surrogate bit set, then we ignore the fact that it is a reparse point because it is actually a file or directory directly there, despite having additional handling by drivers due to the reparse point.
* For everything which is not a symbolic link (including non-surrogate reparse points) we report whether it is a directory or a file based on the presence of the directory attribute bit.
* Notably this still preserves invariant that when `is_symlink` returns `true`, both `is_dir` and `is_file` will return `false`. The potential for breakage was far too high.
* Adds an unstable `FileTypeExt` to allow users to determine whether a symbolic link is a directory or a file, since `FileType` by design is incapable of reporting this information.
2018-02-17 11:32:16 +00:00
..
backtrace Print inlined functions on Windows 2018-01-26 04:49:54 +01:00
ext Add an unstable FileTypeExt extension trait for Windows 2018-02-11 13:40:46 -05:00
args.rs Better Debug for Args and ArgsOs 2017-06-21 15:40:45 +03:00
c.rs Print inlined functions on Windows 2018-01-26 04:49:54 +01:00
cmath.rs std: Move the cmath module into the sys module 2017-11-08 20:42:23 -08:00
compat.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
condvar.rs Use monotonic time with condition variables. 2016-07-31 12:47:52 +02:00
dynamic_lib.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
env.rs std: Move platform specific env code into sys 2016-10-01 19:32:59 +00:00
fast_thread_local.rs rustc: Enable #[thread_local] for Windows 2017-06-23 16:11:39 -07:00
fs.rs Add an unstable FileTypeExt extension trait for Windows 2018-02-11 13:40:46 -05:00
handle.rs Add Read::initializer. 2017-06-20 20:26:22 -07:00
memchr.rs Move rust memchr impl to libcore 2017-12-13 01:15:18 -06:00
mod.rs std: Avoid use of libc in portable modules 2017-11-09 07:56:44 -08:00
mutex.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
net.rs Implement TcpStream::connect_timeout 2017-07-06 19:35:49 -07:00
os.rs Add current_pid function 2017-10-06 01:15:49 -06:00
os_str.rs Capture environment at spawn 2017-12-24 14:24:31 +00:00
path.rs Remove import of now unused AsciiExt 2017-11-04 19:16:03 +01:00
pipe.rs std: Remove rand crate and module 2017-11-08 20:41:17 -08:00
process.rs Capture environment at spawn 2017-12-24 14:24:31 +00:00
rand.rs std: Remove rand crate and module 2017-11-08 20:41:17 -08:00
rwlock.rs Register new snapshots 2015-08-11 15:11:13 -07:00
stack_overflow.rs Fix warnings during tests 2016-01-26 09:29:28 -08:00
stdio.rs std: Change how EBADF is handled in sys 2017-11-08 20:41:17 -08:00
thread.rs Use a range to identify SIGSEGV in stack guards 2018-01-31 11:41:29 -08:00
thread_local.rs std: Flag Windows TLS dtor symbol as #[used] 2017-11-24 14:28:12 -08:00
time.rs Add Hash impl for SystemTime and Instant 2017-12-19 00:35:43 +03:00