[llvm-commits] CVS: llvm-java/lib/Compiler/Resolver.h Class.cpp
Alkis Evlogimenos
alkis at cs.uiuc.edu
Sun Mar 27 18:48:36 PST 2005
Changes in directory llvm-java/lib/Compiler:
Resolver.h updated: 1.6 -> 1.7
Class.cpp updated: 1.12 -> 1.13
---
Log message:
Remove unneeded function now that we can resolve field descriptors.
---
Diffs of the changes: (+5 -6)
Class.cpp | 7 ++++---
Resolver.h | 4 +---
2 files changed, 5 insertions(+), 6 deletions(-)
Index: llvm-java/lib/Compiler/Resolver.h
diff -u llvm-java/lib/Compiler/Resolver.h:1.6 llvm-java/lib/Compiler/Resolver.h:1.7
--- llvm-java/lib/Compiler/Resolver.h:1.6 Sun Mar 27 20:46:19 2005
+++ llvm-java/lib/Compiler/Resolver.h Sun Mar 27 20:48:25 2005
@@ -76,9 +76,7 @@
const Class* getClass(const std::string& className) {
return getClassForDesc(canonicalizeClassName(className));
}
- const Class* getClass(const Field& field) {
- return getClassForDesc(field.getDescriptor()->str());
- }
+
const Class* getClass(JType type);
const Class* getArrayClass(const Class* clazz) {
Index: llvm-java/lib/Compiler/Class.cpp
diff -u llvm-java/lib/Compiler/Class.cpp:1.12 llvm-java/lib/Compiler/Class.cpp:1.13
--- llvm-java/lib/Compiler/Class.cpp:1.12 Sun Mar 27 20:46:19 2005
+++ llvm-java/lib/Compiler/Class.cpp Sun Mar 27 20:48:25 2005
@@ -157,9 +157,10 @@
// Then we add the rest of the fields.
const Fields& fields = classFile_->getFields();
for (unsigned i = 0, e = fields.size(); i != e; ++i) {
- Field& field = *fields[i];
- if (!field.isStatic())
- addField(field.getName()->str(), resolver_->getClass(field)->getType());
+ Field* field = fields[i];
+ if (!field->isStatic())
+ addField(field->getName()->str(),
+ getClassForDescriptor(field->getDescriptorIndex())->getType());
}
}
More information about the llvm-commits
mailing list