diff options
author | Chris Lattner <sabre@nondot.org> | 2007-09-13 01:17:29 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-09-13 01:17:29 +0000 |
commit | 69de3f4af671bed692f25296ed02c58d399250e8 (patch) | |
tree | b455563383558904cab7ca84072b90b83c739978 | |
parent | 5a5b35c07befab1977812d2669b8e71e6f754d31 (diff) | |
download | llvm-69de3f4af671bed692f25296ed02c58d399250e8.tar.gz |
When dumping out errors about unsupported stuff, emit loc info.
llvm-svn: 41907
-rw-r--r-- | clang/CodeGen/CGBuiltin.cpp | 2 | ||||
-rw-r--r-- | clang/CodeGen/CGExpr.cpp | 2 | ||||
-rw-r--r-- | clang/CodeGen/CGExprAgg.cpp | 4 | ||||
-rw-r--r-- | clang/CodeGen/CGExprComplex.cpp | 4 | ||||
-rw-r--r-- | clang/CodeGen/CGExprScalar.cpp | 4 | ||||
-rw-r--r-- | clang/CodeGen/CGStmt.cpp | 2 |
6 files changed, 9 insertions, 9 deletions
diff --git a/clang/CodeGen/CGBuiltin.cpp b/clang/CodeGen/CGBuiltin.cpp index 03b5c2d09c50..6dbd2725216b 100644 --- a/clang/CodeGen/CGBuiltin.cpp +++ b/clang/CodeGen/CGBuiltin.cpp @@ -28,7 +28,7 @@ RValue CodeGenFunction::EmitBuiltinExpr(unsigned BuiltinID, const CallExpr *E) { return EmitCallExpr(CGM.getBuiltinLibFunction(BuiltinID), E); fprintf(stderr, "Unimplemented builtin!!\n"); - E->dump(); + E->dump(getContext().SourceMgr); // Unknown builtin, for now just dump it out and return undef. if (hasAggregateLLVMType(E->getType())) diff --git a/clang/CodeGen/CGExpr.cpp b/clang/CodeGen/CGExpr.cpp index d5a5c3f25805..86604f94bfb4 100644 --- a/clang/CodeGen/CGExpr.cpp +++ b/clang/CodeGen/CGExpr.cpp @@ -84,7 +84,7 @@ LValue CodeGenFunction::EmitLValue(const Expr *E) { switch (E->getStmtClass()) { default: { fprintf(stderr, "Unimplemented lvalue expr!\n"); - E->dump(); + E->dump(getContext().SourceMgr); llvm::Type *Ty = llvm::PointerType::get(ConvertType(E->getType())); return LValue::MakeAddr(llvm::UndefValue::get(Ty)); } diff --git a/clang/CodeGen/CGExprAgg.cpp b/clang/CodeGen/CGExprAgg.cpp index 7ade13305119..de9e2b5f6f16 100644 --- a/clang/CodeGen/CGExprAgg.cpp +++ b/clang/CodeGen/CGExprAgg.cpp @@ -54,7 +54,7 @@ public: void VisitStmt(Stmt *S) { fprintf(stderr, "Unimplemented agg expr!\n"); - S->dump(); + S->dump(CGF.getContext().SourceMgr); } void VisitParenExpr(ParenExpr *PE) { Visit(PE->getSubExpr()); } @@ -135,7 +135,7 @@ void AggExprEmitter::VisitStmtExpr(const StmtExpr *E) { void AggExprEmitter::VisitBinaryOperator(const BinaryOperator *E) { fprintf(stderr, "Unimplemented aggregate binary expr!\n"); - E->dump(); + E->dump(CGF.getContext().SourceMgr); } void AggExprEmitter::VisitBinAssign(const BinaryOperator *E) { diff --git a/clang/CodeGen/CGExprComplex.cpp b/clang/CodeGen/CGExprComplex.cpp index ec5a1bc71afe..067d2899ce61 100644 --- a/clang/CodeGen/CGExprComplex.cpp +++ b/clang/CodeGen/CGExprComplex.cpp @@ -67,7 +67,7 @@ public: //===--------------------------------------------------------------------===// ComplexPairTy VisitStmt(Stmt *S) { - S->dump(); + S->dump(CGF.getContext().SourceMgr); assert(0 && "Stmt can't have complex result type!"); return ComplexPairTy(); } @@ -233,7 +233,7 @@ void ComplexExprEmitter::EmitStoreOfComplex(ComplexPairTy Val, llvm::Value *Ptr, ComplexPairTy ComplexExprEmitter::VisitExpr(Expr *E) { fprintf(stderr, "Unimplemented complex expr!\n"); - E->dump(); + E->dump(CGF.getContext().SourceMgr); const llvm::Type *EltTy = CGF.ConvertType(E->getType()->getAsComplexType()->getElementType()); llvm::Value *U = llvm::UndefValue::get(EltTy); diff --git a/clang/CodeGen/CGExprScalar.cpp b/clang/CodeGen/CGExprScalar.cpp index 96203f04ba8c..9c2e55f6eae3 100644 --- a/clang/CodeGen/CGExprScalar.cpp +++ b/clang/CodeGen/CGExprScalar.cpp @@ -81,7 +81,7 @@ public: //===--------------------------------------------------------------------===// Value *VisitStmt(Stmt *S) { - S->dump(); + S->dump(CGF.getContext().SourceMgr); assert(0 && "Stmt can't have complex result type!"); return 0; } @@ -374,7 +374,7 @@ EmitComplexToScalarConversion(CodeGenFunction::ComplexPairTy Src, Value *ScalarExprEmitter::VisitExpr(Expr *E) { fprintf(stderr, "Unimplemented scalar expr!\n"); - E->dump(); + E->dump(CGF.getContext().SourceMgr); if (E->getType()->isVoidType()) return 0; return llvm::UndefValue::get(CGF.ConvertType(E->getType())); diff --git a/clang/CodeGen/CGStmt.cpp b/clang/CodeGen/CGStmt.cpp index 3a4fd9576a64..fa15c2e620ce 100644 --- a/clang/CodeGen/CGStmt.cpp +++ b/clang/CodeGen/CGStmt.cpp @@ -39,7 +39,7 @@ void CodeGenFunction::EmitStmt(const Stmt *S) { EmitAggExpr(E, 0, false); } else { printf("Unimplemented stmt!\n"); - S->dump(); + S->dump(getContext().SourceMgr); } break; case Stmt::NullStmtClass: break; |