Mercurial > projects > ldc
comparison ir/irtypestruct.cpp @ 1502:2292878925f4
Add an `llvm::OStream` workalike class for use with `Logger::cout()`, with the
crucial difference being special handling of `llvm::Type`s so they get printed
by name rather than printing their full representation (which can be positively
*huge*).
This allows re-enabling some logger calls that were disabled due to extreme
verbosity.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Tue, 16 Jun 2009 19:31:10 +0200 |
parents | 8d501abecd24 |
children | 755abafbf25d |
comparison
equal
deleted
inserted
replaced
1501:8b9f236dd051 | 1502:2292878925f4 |
---|---|
225 llvm::cast<llvm::OpaqueType>(pa.get())->refineAbstractTypeTo(st); | 225 llvm::cast<llvm::OpaqueType>(pa.get())->refineAbstractTypeTo(st); |
226 | 226 |
227 // name types | 227 // name types |
228 Type::sir->getState()->module->addTypeName(sd->toPrettyChars(), pa.get()); | 228 Type::sir->getState()->module->addTypeName(sd->toPrettyChars(), pa.get()); |
229 | 229 |
230 #if 0 | |
231 IF_LOG Logger::cout() << "final struct type: " << *pa.get() << std::endl; | 230 IF_LOG Logger::cout() << "final struct type: " << *pa.get() << std::endl; |
232 #endif | |
233 | 231 |
234 return pa.get(); | 232 return pa.get(); |
235 } | 233 } |
236 | 234 |
237 ////////////////////////////////////////////////////////////////////////////// | 235 ////////////////////////////////////////////////////////////////////////////// |