[all-commits] [llvm/llvm-project] 1275ab: Improve VFS compatibility on Windows

amccarth-google via All-commits all-commits at lists.llvm.org
Thu Nov 14 08:48:59 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 1275ab1620b665eb06231ce3c4e5068c97d9b618
      https://github.com/llvm/llvm-project/commit/1275ab1620b665eb06231ce3c4e5068c97d9b618
  Author: Adrian McCarthy <amccarth at google.com>
  Date:   2019-11-14 (Thu, 14 Nov 2019)

  Changed paths:
    M clang/test/Index/index-module-with-vfs.m
    M clang/test/Modules/double-quotes.m
    M clang/test/Modules/framework-public-includes-private.m
    M clang/test/VFS/external-names.c
    M clang/test/VFS/framework-import.m
    M clang/test/VFS/implicit-include.c
    M clang/test/VFS/include-mixed-real-and-virtual.c
    M clang/test/VFS/include-real-from-virtual.c
    M clang/test/VFS/include-virtual-from-real.c
    M clang/test/VFS/include.c
    M clang/test/VFS/incomplete-umbrella.m
    M clang/test/VFS/module-import.m
    M clang/test/VFS/real-path-found-first.m
    M clang/test/VFS/relative-path.c
    M clang/test/VFS/umbrella-framework-import-skipnonexist.m
    M llvm/include/llvm/Support/VirtualFileSystem.h
    M llvm/lib/Support/VirtualFileSystem.cpp

  Log Message:
  -----------
  Improve VFS compatibility on Windows

Keys in a virtual file system can be in Posix or Windows form or even
a combination of the two.  Many VFS tests (and a few Clang tests) were
XFAILed on Windows because of false negatives when comparing paths.

First, we default CaseSenstive to false on Windows.  This allows
drive letters like "D:" to match "d:".  Windows filesystems are, by
default, case insensitive, so this makes sense even beyond the drive
letter.

Second, we allow slashes to match backslashes when they're used as the
root component of a path.

Both of these changes are limited to RedirectingFileSystems, so there's
little chance of affecting other path handling.

These changes allow eleven of the VFS tests to pass on Windows as well
as three other Clang tests, so they have re-enabled.

This solves the majority of PR43272.  Additional VFS test failures will
be fixed in separate patches.

Differential Revision: https://reviews.llvm.org/D69958




More information about the All-commits mailing list