mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-30 15:10:33 +00:00
TableGen: use fully qualified name for StringLiteral
Use the qualified name for StringLiteral (llvm::StringLiteral) when generating the sources. This is needed as the generated files may be used out-of-tree (e.g. swift) where you may not have a `using namespace llvm;` resulting in an undefined lookup. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293577 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
51c6922329
commit
91f734b9ab
@ -133,13 +133,13 @@ void IntrinsicEmitter::EmitTargetInfo(const CodeGenIntrinsicTable &Ints,
|
||||
OS << "// Target mapping\n";
|
||||
OS << "#ifdef GET_INTRINSIC_TARGET_DATA\n";
|
||||
OS << "struct IntrinsicTargetInfo {\n"
|
||||
<< " StringLiteral Name;\n"
|
||||
<< " llvm::StringLiteral Name;\n"
|
||||
<< " size_t Offset;\n"
|
||||
<< " size_t Count;\n"
|
||||
<< "};\n";
|
||||
OS << "static constexpr IntrinsicTargetInfo TargetInfos[] = {\n";
|
||||
for (auto Target : Ints.Targets)
|
||||
OS << " {StringLiteral(\"" << Target.Name << "\"), " << Target.Offset
|
||||
OS << " {llvm::StringLiteral(\"" << Target.Name << "\"), " << Target.Offset
|
||||
<< ", " << Target.Count << "},\n";
|
||||
OS << "};\n";
|
||||
OS << "#endif\n\n";
|
||||
|
Loading…
Reference in New Issue
Block a user