Skip to content

Commit

Permalink
Undo include order work-around in Regex.cpp
Browse files Browse the repository at this point in the history
r327256 / 2b8b90a added this
include-order work-around since regex_impl.h's include guard conflicted
with macOS's xlocale.h which used the same macro.

Since b86c249 renamed the include
guard, that work-around is no longer needed.

Differential revision: https://reviews.llvm.org/D150127
  • Loading branch information
zmodem committed May 9, 2023
1 parent 706e811 commit 9d7eb60
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions llvm/lib/Support/Regex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,11 @@
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/Twine.h"
#include "regex_impl.h"

#include <cassert>
#include <string>

// Important this comes last because it defines "_REGEX_H_". At least on
// Darwin, if included before any header that (transitively) includes
// xlocale.h, this will cause trouble, because of missing regex-related types.
#include "regex_impl.h"

using namespace llvm;

Regex::Regex() : preg(nullptr), error(REG_BADPAT) {}
Expand Down

0 comments on commit 9d7eb60

Please sign in to comment.