зеркало из https://github.com/microsoft/clang-1.git
Fixed CXX struct and class initialization printing to support 'move'
type constructors. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143309 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
01c770d6c9
Коммит
5eca37c7fe
|
@ -616,7 +616,7 @@ void DeclPrinter::VisitVarDecl(VarDecl *D) {
|
||||||
Out << "(";
|
Out << "(";
|
||||||
else {
|
else {
|
||||||
CXXConstructExpr *CCE = dyn_cast<CXXConstructExpr>(Init);
|
CXXConstructExpr *CCE = dyn_cast<CXXConstructExpr>(Init);
|
||||||
if (!CCE || CCE->getConstructor()->isCopyConstructor())
|
if (!CCE || CCE->getConstructor()->isCopyOrMoveConstructor())
|
||||||
Out << " = ";
|
Out << " = ";
|
||||||
}
|
}
|
||||||
Init->printPretty(Out, Context, 0, Policy, Indentation);
|
Init->printPretty(Out, Context, 0, Policy, Indentation);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче