diff options
author | Sylvestre Ledru <sylvestre@debian.org> | 2021-02-03 09:17:53 +0100 |
---|---|---|
committer | Sylvestre Ledru <sylvestre@debian.org> | 2021-02-03 09:17:53 +0100 |
commit | afdfb726efe1c9bd3419e7990735fcff2ccccebe (patch) | |
tree | f249038eb6b673c4ed18e061182d707ff292a8b2 | |
parent | be90a1405ff602e42635108e485b50a0f631363e (diff) | |
parent | 5c8ed5873e462f740c85c06a3e0afabeaaaad302 (diff) |
Merge branch 'master' of salsa.debian.org:pkg-llvm-team/iwyu8.15-2
-rw-r--r-- | debian/patches/series | 4 | ||||
-rw-r--r-- | debian/patches/stringref.patch | 146 |
2 files changed, 0 insertions, 150 deletions
diff --git a/debian/patches/series b/debian/patches/series index 06a6a12..151ff26 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,5 +1 @@ -#struct.patch python3.diff -stringref.patch -GlobalSourceManager.patch -PrintableStmt.patch diff --git a/debian/patches/stringref.patch b/debian/patches/stringref.patch deleted file mode 100644 index 171dca2..0000000 --- a/debian/patches/stringref.patch +++ /dev/null @@ -1,146 +0,0 @@ -From 53487d209729d5781007dc0fd6076dc585cb3727 Mon Sep 17 00:00:00 2001 -From: Andrea Bocci <andrea.bocci@cern.ch> -Date: Fri, 28 Feb 2020 17:45:03 +0100 -Subject: [PATCH] Add explicit conversion from llvm::StringRef to std::string - -llvm/llvm-project@777180a makes the llvm::StringRef conversion operator -to std::string explicit. -These changes add a call to the str() method to perform the conversion. - -Signed-off-by: Andrea Bocci <andrea.bocci@cern.ch> ---- - iwyu_driver.cc | 2 +- - iwyu_globals.cc | 4 ++-- - iwyu_lexer_utils.cc | 2 +- - iwyu_location_util.h | 2 +- - iwyu_output.cc | 2 +- - iwyu_path_util.cc | 6 +++--- - iwyu_preprocessor.cc | 4 ++-- - 7 files changed, 11 insertions(+), 11 deletions(-) - -diff --git a/iwyu_driver.cc b/iwyu_driver.cc -index bd163144..42fea35b 100644 ---- a/iwyu_driver.cc -+++ b/iwyu_driver.cc -@@ -79,7 +79,7 @@ std::string GetExecutablePath(const char *Argv0) { - } - - const char *SaveStringInSet(std::set<std::string> &SavedStrings, StringRef S) { -- return SavedStrings.insert(S).first->c_str(); -+ return SavedStrings.insert(S.str()).first->c_str(); - } - - void ExpandArgsFromBuf(const char *Arg, -diff --git a/iwyu_globals.cc b/iwyu_globals.cc -index 0f58b4dc..26998966 100644 ---- a/iwyu_globals.cc -+++ b/iwyu_globals.cc -@@ -293,7 +293,7 @@ static vector<HeaderSearchPath> ComputeHeaderSearchPaths( - for (auto it = header_search->system_dir_begin(); - it != header_search->system_dir_end(); ++it) { - if (const DirectoryEntry* entry = it->getDir()) { -- const string path = NormalizeDirPath(MakeAbsolutePath(entry->getName())); -+ const string path = NormalizeDirPath(MakeAbsolutePath(entry->getName().str())); - search_path_map[path] = HeaderSearchPath::kSystemPath; - } - } -@@ -303,7 +303,7 @@ static vector<HeaderSearchPath> ComputeHeaderSearchPaths( - // search_dir_begin()/end() includes both system and user paths. - // If it's a system path, it's already in the map, so everything - // new is a user path. The insert only 'takes' for new entries. -- const string path = NormalizeDirPath(MakeAbsolutePath(entry->getName())); -+ const string path = NormalizeDirPath(MakeAbsolutePath(entry->getName().str())); - search_path_map.insert(make_pair(path, HeaderSearchPath::kUserPath)); - } - } -diff --git a/iwyu_lexer_utils.cc b/iwyu_lexer_utils.cc -index fcea2d28..648c9da8 100644 ---- a/iwyu_lexer_utils.cc -+++ b/iwyu_lexer_utils.cc -@@ -70,7 +70,7 @@ SourceLocation GetLocationAfter( - string GetIncludeNameAsWritten( - SourceLocation include_loc, - const CharacterDataGetterInterface& data_getter) { -- const string data = GetSourceTextUntilEndOfLine(include_loc, data_getter); -+ const string data = GetSourceTextUntilEndOfLine(include_loc, data_getter).str(); - if (data.empty()) - return data; - string::size_type endpos = string::npos; -diff --git a/iwyu_location_util.h b/iwyu_location_util.h -index 3892a424..6f8cf81c 100644 ---- a/iwyu_location_util.h -+++ b/iwyu_location_util.h -@@ -89,7 +89,7 @@ bool IsInScratchSpace(clang::SourceLocation loc); - - inline string GetFilePath(const clang::FileEntry* file) { - return (IsBuiltinFile(file) ? "<built-in>" : -- NormalizeFilePath(file->getName())); -+ NormalizeFilePath(file->getName().str())); - } - - //------------------------------------------------------------ -diff --git a/iwyu_output.cc b/iwyu_output.cc -index ca145710..8666c26c 100644 ---- a/iwyu_output.cc -+++ b/iwyu_output.cc -@@ -168,7 +168,7 @@ string GetKindName(const clang::TagDecl* tag_decl) { - if (const FakeNamedDecl* fake = FakeNamedDeclIfItIsOne(named_decl)) { - return fake->kind_name(); - } -- return tag_decl->getKindName(); -+ return tag_decl->getKindName().str(); - } - - string GetQualifiedNameAsString(const clang::NamedDecl* named_decl) { -diff --git a/iwyu_path_util.cc b/iwyu_path_util.cc -index ab4fc800..9987ea47 100644 ---- a/iwyu_path_util.cc -+++ b/iwyu_path_util.cc -@@ -134,7 +134,7 @@ string NormalizeFilePath(const string& path) { - std::replace(normalized.begin(), normalized.end(), '\\', '/'); - #endif - -- return normalized.str(); -+ return normalized.str().str(); - } - - string NormalizeDirPath(const string& path) { -@@ -154,14 +154,14 @@ string MakeAbsolutePath(const string& path) { - std::error_code error = llvm::sys::fs::make_absolute(absolute_path); - CHECK_(!error); - -- return absolute_path.str(); -+ return absolute_path.str().str(); - } - - string MakeAbsolutePath(const string& base_path, const string& relative_path) { - llvm::SmallString<128> absolute_path(base_path); - llvm::sys::path::append(absolute_path, relative_path); - -- return absolute_path.str(); -+ return absolute_path.str().str(); - } - - string GetParentPath(const string& path) { -diff --git a/iwyu_preprocessor.cc b/iwyu_preprocessor.cc -index 58e78595..88b93144 100644 ---- a/iwyu_preprocessor.cc -+++ b/iwyu_preprocessor.cc -@@ -313,7 +313,7 @@ void IwyuPreprocessorInfo::ProcessHeadernameDirectivesInFile( - break; - } - const string filename = GetSourceTextUntilEndOfLine(current_loc, -- DefaultDataGetter()); -+ DefaultDataGetter()).str(); - // Use "" or <> based on where the file lives. - string quoted_private_include; - if (IsSystemIncludeFile(GetFilePath(current_loc))) -@@ -332,7 +332,7 @@ void IwyuPreprocessorInfo::ProcessHeadernameDirectivesInFile( - } - - string after_text = GetSourceTextUntilEndOfLine(current_loc, -- DefaultDataGetter()); -+ DefaultDataGetter()).str(); - const string::size_type close_brace_pos = after_text.find('}'); - if (close_brace_pos == string::npos) { - Warn(current_loc, "@headername directive missing a closing brace"); |