[llvm] r373742 - Fix uninitialized variable warnings in directory_entry default constructor. NFCI
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 4 05:45:42 PDT 2019
Author: rksimon
Date: Fri Oct 4 05:45:42 2019
New Revision: 373742
URL: http://llvm.org/viewvc/llvm-project?rev=373742&view=rev
Log:
Fix uninitialized variable warnings in directory_entry default constructor. NFCI
Modified:
llvm/trunk/include/llvm/Support/FileSystem.h
Modified: llvm/trunk/include/llvm/Support/FileSystem.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/FileSystem.h?rev=373742&r1=373741&r2=373742&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/FileSystem.h (original)
+++ llvm/trunk/include/llvm/Support/FileSystem.h Fri Oct 4 05:45:42 2019
@@ -1215,9 +1215,9 @@ class directory_entry {
// that whole structure, callers end up paying for a stat().
// std::filesystem::directory_entry may be a better model.
std::string Path;
- file_type Type; // Most platforms can provide this.
- bool FollowSymlinks; // Affects the behavior of status().
- basic_file_status Status; // If available.
+ file_type Type = file_type::type_unknown; // Most platforms can provide this.
+ bool FollowSymlinks = true; // Affects the behavior of status().
+ basic_file_status Status; // If available.
public:
explicit directory_entry(const Twine &Path, bool FollowSymlinks = true,
More information about the llvm-commits
mailing list