Home
last modified time | relevance | path

Searched refs:FilePath (Results 1 – 25 of 123) sorted by relevance

12345

/llvm-project/third-party/unittest/googletest/src/
H A Dgtest-filepath.cc101 FilePath FilePath::GetCurrentDir() { in GetCurrentDir()
109 return FilePath(kCurrentDirectoryString); in GetCurrentDir()
112 return FilePath(_getcwd(cwd, sizeof(cwd)) == nullptr ? "" : cwd); in GetCurrentDir()
120 return FilePath(result == nullptr ? kCurrentDirectoryString : cwd); in GetCurrentDir()
122 return FilePath(result == nullptr ? "" : cwd); in GetCurrentDir()
130 FilePath FilePath::RemoveExtension(const char* extension) const { in RemoveExtension()
133 return FilePath( in RemoveExtension()
142 const char* FilePath::FindLastPathSeparator() const { in FindLastPathSeparator()
155 size_t FilePath::CalculateRootLength() const { in CalculateRootLength()
199 FilePath FilePath::RemoveDirectoryName() const { in RemoveDirectoryName()
[all …]
/llvm-project/third-party/unittest/googletest/include/gtest/internal/
H A Dgtest-filepath.h69 class GTEST_API_ FilePath {
71 FilePath() : pathname_("") {} in FilePath() function
72 FilePath(const FilePath& rhs) : pathname_(rhs.pathname_) {} in FilePath() function
74 explicit FilePath(const std::string& pathname) : pathname_(pathname) { in FilePath() function
78 FilePath& operator=(const FilePath& rhs) {
83 void Set(const FilePath& rhs) { pathname_ = rhs.pathname_; } in Set()
89 static FilePath GetCurrentDir();
95 static FilePath MakeFileName(const FilePath& directory,
96 const FilePath& base_name, int number,
102 static FilePath ConcatPaths(const FilePath& directory,
[all …]
/llvm-project/clang-tools-extra/clangd/refactor/tweaks/
H A DScopifyEnum.cpp65 llvm::Expected<StringRef> getContentForFile(StringRef FilePath);
68 llvm::Error addReplacement(StringRef FilePath, StringRef Content,
114 static const auto MakeReplacement = [](StringRef FilePath, in addClassKeywordToDeclarations()
116 return tooling::Replacement(FilePath, Offset, 0, "class "); in addClassKeywordToDeclarations()
149 const auto MakeReplacement = [&EnumName](StringRef FilePath, in scopifyEnumValue()
155 return tooling::Replacement(FilePath, Offset, Length, {}); in scopifyEnumValue()
163 const auto MakeReplacement = [&](StringRef FilePath, StringRef Content, in scopifyEnumValue() argument
189 return tooling::Replacement(FilePath, Offset, in scopifyEnumValue()
191 return tooling::Replacement(FilePath, Offset + EnumName.size(), in scopifyEnumValue()
195 : tooling::Replacement(FilePath, Offset, 0, in scopifyEnumValue()
[all …]
/llvm-project/clang-tools-extra/modularize/
H A DModuleAssistant.cpp174 std::string FilePath; in addModuleDescription()
181 FilePath = std::string(NativePath.substr(NativePrefix.size() + 1)); in addModuleDescription()
183 FilePath = std::string(HeaderFilePath); in addModuleDescription()
188 llvm::errs() << "warning: " << FilePath in addModuleDescription()
195 std::replace(FilePath.begin(), FilePath.end(), '\\', '/'); in addModuleDescription()
197 for (llvm::sys::path::const_iterator I = llvm::sys::path::begin(FilePath), in addModuleDescription()
198 E = llvm::sys::path::end(FilePath); in addModuleDescription()
213 CurrentModule->HeaderFileNames.push_back(FilePath); in addModuleDescription()
258 llvm::SmallString<256> FilePath; in writeModuleMap()
172 std::string FilePath; addModuleDescription() local
256 llvm::SmallString<256> FilePath; writeModuleMap() local
[all...]
H A DModularizeUtilities.cpp443 // \param FilePath The file path, relative to the module map directory. in replaceDotDot()
445 std::string ModularizeUtilities::getCanonicalPath(StringRef FilePath) { in replaceDotDot()
446 std::string Tmp(replaceDotDot(FilePath)); in replaceDotDot()
485 void ModularizeUtilities::addUniqueProblemFile(std::string FilePath) { in getDirectoryFromPath()
486 FilePath = getCanonicalPath(FilePath); in getDirectoryFromPath()
489 if (TestFilePath == FilePath) in getDirectoryFromPath()
492 ProblemFileNames.push_back(FilePath);
497 void ModularizeUtilities::addNoCompileErrorsFile(std::string FilePath) { in addUniqueProblemFile()
498 FilePath in addUniqueProblemFile()
453 getCanonicalPath(StringRef FilePath) getCanonicalPath() argument
493 addUniqueProblemFile(std::string FilePath) addUniqueProblemFile() argument
505 addNoCompileErrorsFile(std::string FilePath) addNoCompileErrorsFile() argument
[all...]
/llvm-project/clang/unittests/Tooling/
H A DDiagnosticsYamlTest.cpp25 const std::string &FilePath, const StringMap<Replacements> &Fix, in makeMessage() argument
30 DiagMessage.FilePath = FilePath; in makeMessage()
38 const std::string &FilePath) { in makeByteRange() argument
42 Range.FilePath = FilePath; in makeByteRange()
48 const std::string &FilePath, in makeDiagnostic() argument
53 makeMessage(Message, FileOffset, FilePath, Fix, Ranges), {}, in makeDiagnostic()
64 " FilePath: 'path/to/source.cpp'\n"
67 " - FilePath
[all...]
/llvm-project/clang-tools-extra/clang-include-fixer/find-all-symbols/
H A DPathConfig.cpp19 llvm::StringRef FilePath; in getIncludePath() local
24 FilePath = SM.getFilename(Loc); in getIncludePath()
25 if (FilePath.empty()) in getIncludePath()
27 if (!FilePath.ends_with(".inc")) in getIncludePath()
34 FilePath = Collector->getMappedHeader(FilePath); in getIncludePath()
35 SmallString<256> CleanedFilePath = FilePath; in getIncludePath()
H A DSymbolInfo.cpp30 io.mapRequired("FilePath", Symbol.Symbol.FilePath); in mapping()
72 llvm::StringRef FilePath, in SymbolInfo() argument
74 : Name(Name), Type(Type), FilePath(FilePath), Contexts(Contexts) {} in SymbolInfo()
77 return std::tie(Name, Type, FilePath, Contexts) == in operator ==()
78 std::tie(Symbol.Name, Symbol.Type, Symbol.FilePath, Symbol.Contexts); in operator ==()
82 return std::tie(Name, Type, FilePath, Contexts) < in operator <()
83 std::tie(Symbol.Name, Symbol.Type, Symbol.FilePath, Symbol.Contexts); in operator <()
H A DSymbolInfo.h73 SymbolInfo(llvm::StringRef Name, SymbolKind Type, llvm::StringRef FilePath,
76 void SetFilePath(llvm::StringRef Path) { FilePath = std::string(Path); } in SetFilePath()
88 llvm::StringRef getFilePath() const { return FilePath; } in getFilePath()
110 std::string FilePath;
/llvm-project/clang/lib/Tooling/Refactoring/
H A DAtomicChange.cpp30 : Key(E.getKey()), FilePath(E.getFilePath()), Error(E.getError()), in NormalizedAtomicChange()
41 std::string FilePath; member
57 Io.mapRequired("FilePath", Doc.FilePath); in mapping()
72 Io.mapRequired("FilePath", Keys->FilePath); in mapping()
144 createReplacementsForHeaders(llvm::StringRef FilePath, llvm::StringRef Code, in createReplacementsForHeaders() argument
160 tooling::Replacement(FilePath, UINT_MAX, 0, ReplacementText)); in createReplacementsForHeaders()
168 HeaderReplacements.add(Replacement(FilePath, UINT_MAX, 1, Header)); in createReplacementsForHeaders()
181 // file path in all replacements and replaces them with \p FilePath
183 combineReplacementsInChanges(llvm::StringRef FilePath,llvm::ArrayRef<AtomicChange> Changes) combineReplacementsInChanges() argument
213 AtomicChange(std::string Key,std::string FilePath,std::string Error,std::vector<std::string> InsertedHeaders,std::vector<std::string> RemovedHeaders,clang::tooling::Replacements Replaces) AtomicChange() argument
301 applyAtomicChanges(llvm::StringRef FilePath,llvm::StringRef Code,llvm::ArrayRef<AtomicChange> Changes,const ApplyChangesSpec & Spec) applyAtomicChanges() argument
[all...]
/llvm-project/clang/lib/Format/
H A DMatchFilePath.cpp22 // Check whether `FilePath` matches `Pattern` based on POSIX 2.13.1, 2.13.2, and
24 bool matchFilePath(StringRef Pattern, StringRef FilePath) { in matchFilePath() argument
26 assert(!FilePath.empty()); in matchFilePath()
28 const auto FilePathBack = FilePath.back(); in matchFilePath()
31 // character of `FilePath`. in matchFilePath()
37 const auto End = FilePath.size(); // End of `FilePath`. in matchFilePath()
44 switch (const auto F = FilePath[J]; Pattern[I]) { in matchFilePath()
61 const auto K = FilePath.find(Separator, J); // Index of next `Separator`. in matchFilePath()
76 J = K; // Skip to next `Separator` in `FilePath` in matchFilePath()
[all...]
/llvm-project/clang/include/clang/Tooling/Refactoring/
H A DAtomicChange.h49 AtomicChange(llvm::StringRef FilePath, llvm::StringRef Key) in AtomicChange() argument
50 : Key(Key), FilePath(FilePath) {} in AtomicChange()
71 const std::string &getFilePath() const { return FilePath; } in getFilePath()
134 AtomicChange(std::string Key, std::string FilePath, std::string Error,
141 std::string FilePath; variable
185 applyAtomicChanges(llvm::StringRef FilePath, llvm::StringRef Code,
/llvm-project/clang-tools-extra/clang-tidy/misc/
H A DHeaderIncludeCycleCheck.cpp70 std::optional<llvm::StringRef> FilePath = SM.getNonBuiltinFilenameForID(Id); in FileChanged() local
72 FilePath ? llvm::sys::path::filename(*FilePath) : llvm::StringRef(); in FileChanged()
83 void InclusionDirective(SourceLocation, const Token &, StringRef FilePath, in InclusionDirective() argument
91 llvm::StringRef FileName = llvm::sys::path::filename(FilePath); in InclusionDirective()
119 const std::optional<StringRef> FilePath = SM.getNonBuiltinFilenameForID(Id); in checkForDoubleInclude() local
120 if (!FilePath || isFileIgnored(*FilePath)) in checkForDoubleInclude()
/llvm-project/clang-tools-extra/clang-doc/assets/
H A Dindex.js12 computeRelativePath(FilePath, CurrentDirectory) global() argument
/llvm-project/clang/include/clang/IndexSerialization/
H A DSerializablePathCollection.h60 struct FilePath { struct
64 FilePath(const DirPath &Dir, const StringPool::StringOffsetSize &Filename) in FilePath() argument
75 llvm::ArrayRef<FilePath> getFilePaths() const;
81 std::vector<FilePath> FilePaths;
107 ArrayRef<PathPool::FilePath> getFilePaths() const { in getFilePaths()
/llvm-project/clang/include/clang/Tooling/
H A DReplacementsYaml.h36 : FilePath(R.getFilePath()), Offset(R.getOffset()), in LLVM_YAML_IS_SEQUENCE_VECTOR()
40 return clang::tooling::Replacement(FilePath, Offset, Length, in LLVM_YAML_IS_SEQUENCE_VECTOR()
44 std::string FilePath; in LLVM_YAML_IS_SEQUENCE_VECTOR()
53 Io.mapRequired("FilePath", Keys->FilePath); in LLVM_YAML_IS_SEQUENCE_VECTOR()
/llvm-project/llvm/lib/CodeGen/
H A DJMCInstrumenter.cpp89 SmallString<256> FilePath(SP.getDirectory()); in getFlagName() local
90 sys::path::append(FilePath, PathStyle, SP.getFilename()); in getFlagName()
91 sys::path::native(FilePath, PathStyle); in getFlagName()
92 sys::path::remove_dots(FilePath, /*remove_dot_dot=*/true, PathStyle); in getFlagName()
101 for (auto C : sys::path::filename(FilePath, PathStyle)) in getFlagName()
104 sys::path::remove_filename(FilePath, PathStyle); in getFlagName()
106 utohexstr(djbHash(FilePath), /*LowerCase=*/false, in getFlagName()
/llvm-project/clang/lib/Tooling/Core/
H A DDiagnostic.cpp29 FilePath = std::string(Sources.getFilename(Loc)); in DiagnosticMessage()
34 if (!FilePath.empty()) in DiagnosticMessage()
41 FilePath = std::string(Sources.getFilename(Range.getBegin())); in FileByteRange()
42 if (!FilePath.empty()) { in FileByteRange()
/llvm-project/clang/lib/Driver/ToolChains/
H A DCuda.cpp229 std::string FilePath = LibDevicePath + "/libdevice.10.bc"; in CudaInstallationDetector()
230 if (FS.exists(FilePath)) { in CudaInstallationDetector()
237 LibDeviceMap[OffloadArchName] = FilePath; in CudaInstallationDetector()
245 StringRef FilePath = LI->path(); in CudaInstallationDetector()
246 StringRef FileName = llvm::sys::path::filename(FilePath); in CudaInstallationDetector()
254 LibDeviceMap[GpuArch] = FilePath.str(); in CudaInstallationDetector()
259 LibDeviceMap["sm_20"] = std::string(FilePath); in CudaInstallationDetector()
260 LibDeviceMap["sm_21"] = std::string(FilePath); in CudaInstallationDetector()
261 LibDeviceMap["sm_32"] = std::string(FilePath); in CudaInstallationDetector()
263 LibDeviceMap["sm_30"] = std::string(FilePath); in CudaInstallationDetector()
224 std::string FilePath = LibDevicePath + "/libdevice.10.bc"; CudaInstallationDetector() local
240 StringRef FilePath = LI->path(); CudaInstallationDetector() local
[all...]
H A DNaCl.cpp213 std::string FilePath(getDriver().Dir + "/../"); in NaClToolChain() local
223 file_paths.push_back(FilePath + "x86_64-nacl/lib32"); in NaClToolChain()
224 file_paths.push_back(FilePath + "i686-nacl/usr/lib"); in NaClToolChain()
229 file_paths.push_back(FilePath + "x86_64-nacl/lib"); in NaClToolChain()
230 file_paths.push_back(FilePath + "x86_64-nacl/usr/lib"); in NaClToolChain()
235 file_paths.push_back(FilePath + "arm-nacl/lib"); in NaClToolChain()
236 file_paths.push_back(FilePath + "arm-nacl/usr/lib"); in NaClToolChain()
241 file_paths.push_back(FilePath + "mipsel-nacl/lib"); in NaClToolChain()
242 file_paths.push_back(FilePath + "mipsel-nacl/usr/lib"); in NaClToolChain()
/llvm-project/llvm/lib/Support/
H A DProcess.cpp58 SmallString<128> FilePath(Dir); in FindInEnvPath()
59 path::append(FilePath, FileName); in FindInEnvPath() local
60 if (fs::exists(Twine(FilePath))) { in FindInEnvPath()
61 FoundPath = std::string(FilePath); in FindInEnvPath()
/llvm-project/clang-tools-extra/clang-include-fixer/
H A DIncludeFixer.h95 void setFilePath(StringRef FilePath) { in setFilePath() argument
96 this->FilePath = std::string(FilePath); in setFilePath()
148 std::string FilePath; variable
H A DIncludeFixer.cpp333 std::string FilePath = Symbol.getFilePath().str(); in getIncludeFixerContext()
335 ((FilePath[0] == '"' || FilePath[0] == '<') ? FilePath in getIncludeFixerContext()
336 : "\"" + FilePath + "\""), in getIncludeFixerContext()
341 return IncludeFixerContext(FilePath, QuerySymbolInfos, SymbolCandidates); in getIncludeFixerContext()
411 StringRef FilePath = Context.getFilePath(); in createIncludeFixerReplacements()
417 Insertions.add(tooling::Replacement(FilePath, UINT_MAX, 0, IncludeName)); in createIncludeFixerReplacements()
431 {FilePath, Info.Range.getOffset(), Info.Range.getLength(), in createIncludeFixerReplacements()
332 std::string FilePath = Symbol.getFilePath().str(); getIncludeFixerContext() local
410 StringRef FilePath = Context.getFilePath(); createIncludeFixerReplacements() local
/llvm-project/clang-tools-extra/test/clang-include-fixer/
H A Dmerge.test9 FilePath: '../include/bar.h'
19 FilePath: '../include/barbar.h'
29 FilePath: foo.h
/llvm-project/clang-tools-extra/clang-doc/tool/
H A DClangDocMain.cpp143 llvm::SmallString<128> FilePath(UserAssetPath); in getAssetFiles() local
147 FilePath = DirStart->path(); in getAssetFiles()
148 if (llvm::sys::fs::is_regular_file(FilePath)) { in getAssetFiles()
149 if (llvm::sys::path::extension(FilePath) == ".css") in getAssetFiles()
151 std::string(FilePath)); in getAssetFiles()
152 else if (llvm::sys::path::extension(FilePath) == ".js") in getAssetFiles()
153 CDCtx.JsScripts.emplace_back(FilePath.str()); in getAssetFiles()
157 return llvm::createFileError(FilePath, FileErr); in getAssetFiles()

12345