Implement TODO for better diagnostic output

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1859 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2002-03-11 22:12:39 +00:00
parent 0fce76a009
commit 749ce032ba

View File

@ -82,10 +82,14 @@ static struct PerModuleInfo {
// resolved! // resolved!
// //
if (!GlobalRefs.empty()) { if (!GlobalRefs.empty()) {
// TODO: Make this more detailed! Loop over each undef value and print string UndefinedReferences = "Unresolved global references exist:\n";
// info
ThrowException("TODO: Make better error - Unresolved forward constant " for (GlobalRefsType::iterator I = GlobalRefs.begin(), E =GlobalRefs.end();
"references exist!"); I != E; ++I) {
UndefinedReferences += " " + I->first.first->getDescription() + " " +
I->first.second.getName() + "\n";
}
ThrowException(UndefinedReferences);
} }
Values.clear(); // Clear out method local definitions Values.clear(); // Clear out method local definitions