]> granicus.if.org Git - clang/commitdiff
When creating the declaration reference for implicit copy-construction
authorDouglas Gregor <dgregor@apple.com>
Mon, 3 May 2010 15:43:53 +0000 (15:43 +0000)
committerDouglas Gregor <dgregor@apple.com>
Mon, 3 May 2010 15:43:53 +0000 (15:43 +0000)
of a base class, give it real source-location information. Fixes PR7017.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102916 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaDeclCXX.cpp

index 0db0d9e38963c5ea3e21f2bb942a112cf4a16f52..58be7aecf0839ee95076117089a807fcb3992b93 100644 (file)
@@ -1501,7 +1501,7 @@ BuildImplicitBaseInitializer(Sema &SemaRef, CXXConstructorDecl *Constructor,
     
     Expr *CopyCtorArg = 
       DeclRefExpr::Create(SemaRef.Context, 0, SourceRange(), Param, 
-                          SourceLocation(), ParamType, 0);
+                          Constructor->getLocation(), ParamType, 0);
     
     // Cast to the base class to avoid ambiguities.
     QualType ArgTy =