mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-29 14:40:25 +00:00
remove dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112707 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
d4c454317a
commit
8861e275d0
@ -84,34 +84,6 @@ namespace {
|
||||
}
|
||||
};
|
||||
|
||||
class StructEmitter {
|
||||
private:
|
||||
std::string Name;
|
||||
typedef std::pair<const char*, const char*> member;
|
||||
std::vector< member > Members;
|
||||
public:
|
||||
StructEmitter(const char *N) : Name(N) {
|
||||
}
|
||||
void addMember(const char *t, const char *n) {
|
||||
member m(t, n);
|
||||
Members.push_back(m);
|
||||
}
|
||||
void emit(raw_ostream &o, unsigned int &i) {
|
||||
o.indent(i) << "struct " << Name.c_str() << " {" << "\n";
|
||||
i += 2;
|
||||
|
||||
unsigned int index = 0;
|
||||
unsigned int numMembers = Members.size();
|
||||
for (index = 0; index < numMembers; ++index) {
|
||||
o.indent(i) << Members[index].first << " ";
|
||||
o.indent(i) << Members[index].second << ";" << "\n";
|
||||
}
|
||||
|
||||
i -= 2;
|
||||
o.indent(i) << "};" << "\n";
|
||||
}
|
||||
};
|
||||
|
||||
class ConstantEmitter {
|
||||
public:
|
||||
virtual ~ConstantEmitter() { }
|
||||
@ -126,10 +98,6 @@ namespace {
|
||||
const char* String;
|
||||
};
|
||||
public:
|
||||
LiteralConstantEmitter(const char *string) :
|
||||
IsNumber(false),
|
||||
String(string) {
|
||||
}
|
||||
LiteralConstantEmitter(int number = 0) :
|
||||
IsNumber(true),
|
||||
Number(number) {
|
||||
@ -139,11 +107,6 @@ namespace {
|
||||
Number = 0;
|
||||
String = string;
|
||||
}
|
||||
void set(int number) {
|
||||
IsNumber = true;
|
||||
String = NULL;
|
||||
Number = number;
|
||||
}
|
||||
bool is(const char *string) {
|
||||
return !strcmp(String, string);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user