mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-14 23:48:56 +00:00
[globalisel][tablegen] Fix an issue with lambdas when compiling with older GCC's
It seems that G++ 4.8 doesn't accept the 'enum A' in code of the form: enum A { ... }; const auto &F = []() -> enum A { ... }; However, it does accept: typedef enum { ... } A; const auto &F = []() -> A { ... }; git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@308599 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b16c6ff827
commit
35ce55c79f
@ -29,8 +29,8 @@ bool InstructionSelector::executeMatchTable(
|
||||
uint64_t CurrentIdx = 0;
|
||||
SmallVector<uint64_t, 8> OnFailResumeAt;
|
||||
|
||||
enum RejectAction { RejectAndGiveUp, RejectAndResume };
|
||||
auto handleReject = [&]() -> enum RejectAction {
|
||||
typedef enum { RejectAndGiveUp, RejectAndResume } RejectAction;
|
||||
auto handleReject = [&]() -> RejectAction {
|
||||
DEBUG(dbgs() << CurrentIdx << ": Rejected\n");
|
||||
if (OnFailResumeAt.empty())
|
||||
return RejectAndGiveUp;
|
||||
|
Loading…
Reference in New Issue
Block a user