From aab9c520309a75c8f7637b130033704651c69701 Mon Sep 17 00:00:00 2001 From: Roberto Raggi Date: Mon, 10 May 2010 09:44:18 +0200 Subject: More work on template instantiation. --- src/shared/cplusplus/Symbol.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/shared/cplusplus') diff --git a/src/shared/cplusplus/Symbol.cpp b/src/shared/cplusplus/Symbol.cpp index 29865c9922..6c506c1700 100644 --- a/src/shared/cplusplus/Symbol.cpp +++ b/src/shared/cplusplus/Symbol.cpp @@ -242,6 +242,8 @@ void Symbol::setSourceLocation(unsigned sourceLocation) unsigned Symbol::line() const { + assert(_sourceOffset != 0); + unsigned line = 0, column = 0; const StringLiteral *fileId = 0; translationUnit()->getPosition(_sourceOffset, &line, &column, &fileId); @@ -250,6 +252,8 @@ unsigned Symbol::line() const unsigned Symbol::column() const { + assert(_sourceOffset != 0); + unsigned line = 0, column = 0; const StringLiteral *fileId = 0; translationUnit()->getPosition(_sourceOffset, &line, &column, &fileId); @@ -258,6 +262,8 @@ unsigned Symbol::column() const const StringLiteral *Symbol::fileId() const { + assert(_sourceOffset != 0); + unsigned line = 0, column = 0; const StringLiteral *fileId = 0; translationUnit()->getPosition(_sourceOffset, &line, &column, &fileId); -- cgit v1.2.1