Skip to content

Commit b7d8c61

Browse files
committed
[TextAPI] Add missing include for Expected type
1 parent f530eee commit b7d8c61

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

llvm/include/llvm/TextAPI/Utils.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#define LLVM_TEXTAPI_UTILS_H
1515

1616
#include "llvm/ADT/Twine.h"
17+
#include "llvm/Support/Error.h"
1718
#include "llvm/Support/FileSystem.h"
1819
#include "llvm/Support/Path.h"
1920
#include "llvm/Support/Regex.h"

llvm/lib/TextAPI/Utils.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ bool llvm::MachO::isPrivateLibrary(StringRef Path, bool IsSymLink) {
155155

156156
static StringLiteral RegexMetachars = "()^$|+.[]\\{}";
157157

158-
Expected<Regex> llvm::MachO::createRegexFromGlob(StringRef Glob) {
158+
llvm::Expected<Regex> llvm::MachO::createRegexFromGlob(StringRef Glob) {
159159
SmallString<128> RegexString("^");
160160
unsigned NumWildcards = 0;
161161
for (unsigned i = 0; i < Glob.size(); ++i) {
@@ -191,7 +191,7 @@ Expected<Regex> llvm::MachO::createRegexFromGlob(StringRef Glob) {
191191
if (NumWildcards == 0)
192192
return make_error<StringError>("not a glob", inconvertibleErrorCode());
193193

194-
auto Rule = Regex(RegexString);
194+
llvm::Regex Rule = Regex(RegexString);
195195
std::string Error;
196196
if (!Rule.isValid(Error))
197197
return make_error<StringError>(Error, inconvertibleErrorCode());

0 commit comments

Comments
 (0)