[llvm-commits] CVS: llvm-java/lib/Compiler/Compiler.cpp
Alkis Evlogimenos
alkis at cs.uiuc.edu
Sat Dec 4 20:07:38 PST 2004
Changes in directory llvm-java/lib/Compiler:
Compiler.cpp updated: 1.157 -> 1.158
---
Log message:
Make check for constructor methods more efficient.
---
Diffs of the changes: (+2 -2)
Index: llvm-java/lib/Compiler/Compiler.cpp
diff -u llvm-java/lib/Compiler/Compiler.cpp:1.157 llvm-java/lib/Compiler/Compiler.cpp:1.158
--- llvm-java/lib/Compiler/Compiler.cpp:1.157 Sat Dec 4 22:05:04 2004
+++ llvm-java/lib/Compiler/Compiler.cpp Sat Dec 4 22:07:27 2004
@@ -393,7 +393,7 @@
Method* method = methods[i];
// The contructor is the only non-static method that is not
// dynamically dispatched so we skip it.
- if (!method->isStatic() && method->getName()->str() != "<init>") {
+ if (!method->isStatic() && method->getName()->str()[0] != '<') {
std::string methodDescr =
method->getName()->str() +
method->getDescriptor()->str();
@@ -764,7 +764,7 @@
Method* method = methods[i];
// The contructor is the only non-static method that is not
// dynamically dispatched so we skip it.
- if (!method->isStatic() && method->getName()->str() != "<init>") {
+ if (!method->isStatic() && method->getName()->str()[0] != '<') {
const std::string& methodDescr =
method->getName()->str() + method->getDescriptor()->str();
More information about the llvm-commits
mailing list