mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Fix an ODR violation consisting of two 'struct Query' in the global namespace.
Put them in their own anonymous namespaces. Found by GCC's new -Wodr (PR20915). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217662 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -41,6 +41,7 @@ enum { RecursionLimit = 3 };
|
||||
STATISTIC(NumExpand, "Number of expansions");
|
||||
STATISTIC(NumReassoc, "Number of reassociations");
|
||||
|
||||
namespace {
|
||||
struct Query {
|
||||
const DataLayout *DL;
|
||||
const TargetLibraryInfo *TLI;
|
||||
@@ -53,6 +54,7 @@ struct Query {
|
||||
const Instruction *cxti = nullptr)
|
||||
: DL(DL), TLI(tli), DT(dt), AT(at), CxtI(cxti) {}
|
||||
};
|
||||
} // end anonymous namespace
|
||||
|
||||
static Value *SimplifyAndInst(Value *, Value *, const Query &, unsigned);
|
||||
static Value *SimplifyBinOp(unsigned, Value *, Value *, const Query &,
|
||||
|
Reference in New Issue
Block a user