[llvm-commits] CVS: llvm/lib/Target/CBackend/Writer.cpp
Chris Lattner
lattner at cs.uiuc.edu
Sat Mar 5 18:28:42 PST 2005
Changes in directory llvm/lib/Target/CBackend:
Writer.cpp updated: 1.227 -> 1.228
---
Log message:
simplify some code.
---
Diffs of the changes: (+4 -5)
Writer.cpp | 9 ++++-----
1 files changed, 4 insertions(+), 5 deletions(-)
Index: llvm/lib/Target/CBackend/Writer.cpp
diff -u llvm/lib/Target/CBackend/Writer.cpp:1.227 llvm/lib/Target/CBackend/Writer.cpp:1.228
--- llvm/lib/Target/CBackend/Writer.cpp:1.227 Thu Mar 3 15:12:04 2005
+++ llvm/lib/Target/CBackend/Writer.cpp Sat Mar 5 20:28:23 2005
@@ -990,13 +990,12 @@
/// type name is found, emit it's declaration...
///
void CWriter::printModuleTypes(const SymbolTable &ST) {
- // If there are no type names, exit early.
- if ( ! ST.hasTypes() )
- return;
-
- // We are only interested in the type plane of the symbol table...
+ // We are only interested in the type plane of the symbol table.
SymbolTable::type_const_iterator I = ST.type_begin();
SymbolTable::type_const_iterator End = ST.type_end();
+
+ // If there are no type names, exit early.
+ if (I == End) return;
// Print out forward declarations for structure types before anything else!
Out << "/* Structure forward decls */\n";
More information about the llvm-commits
mailing list