|
|
|
@ -211,13 +211,13 @@ void NameAST::setGlobal( bool b )
|
|
|
|
|
|
|
|
|
|
void NameAST::setUnqualifiedName( ClassOrNamespaceNameAST::Node& unqualifiedName )
|
|
|
|
|
{
|
|
|
|
|
m_unqualifiedName = unqualifiedName;
|
|
|
|
|
if( m_unqualifiedName.get() ) m_unqualifiedName->setParent( this );
|
|
|
|
|
m_unqualifiedName = std::move(unqualifiedName);
|
|
|
|
|
if( m_unqualifiedName ) m_unqualifiedName->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void NameAST::addClassOrNamespaceName( ClassOrNamespaceNameAST::Node& classOrNamespaceName )
|
|
|
|
|
{
|
|
|
|
|
if( !classOrNamespaceName.get() )
|
|
|
|
|
if( !classOrNamespaceName )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
classOrNamespaceName->setParent( this );
|
|
|
|
@ -226,7 +226,7 @@ void NameAST::addClassOrNamespaceName( ClassOrNamespaceNameAST::Node& classOrNam
|
|
|
|
|
|
|
|
|
|
TQString NameAST::text() const
|
|
|
|
|
{
|
|
|
|
|
if( !m_unqualifiedName.get() )
|
|
|
|
|
if( !m_unqualifiedName )
|
|
|
|
|
return TQString();
|
|
|
|
|
|
|
|
|
|
TQString str;
|
|
|
|
@ -241,7 +241,7 @@ TQString NameAST::text() const
|
|
|
|
|
++it;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if( m_unqualifiedName.get() )
|
|
|
|
|
if( m_unqualifiedName )
|
|
|
|
|
str += m_unqualifiedName->text();
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
@ -260,7 +260,7 @@ LinkageBodyAST::LinkageBodyAST()
|
|
|
|
|
|
|
|
|
|
void LinkageBodyAST::addDeclaration( DeclarationAST::Node& ast )
|
|
|
|
|
{
|
|
|
|
|
if( !ast.get() )
|
|
|
|
|
if( !ast )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
ast->setParent( this );
|
|
|
|
@ -274,20 +274,20 @@ LinkageSpecificationAST::LinkageSpecificationAST()
|
|
|
|
|
|
|
|
|
|
void LinkageSpecificationAST::setExternType( AST::Node& externType )
|
|
|
|
|
{
|
|
|
|
|
m_externType = externType;
|
|
|
|
|
if( m_externType.get() ) m_externType->setParent( this );
|
|
|
|
|
m_externType = std::move(externType);
|
|
|
|
|
if( m_externType ) m_externType->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void LinkageSpecificationAST::setLinkageBody( LinkageBodyAST::Node& linkageBody )
|
|
|
|
|
{
|
|
|
|
|
m_linkageBody = linkageBody;
|
|
|
|
|
if( m_linkageBody.get() ) m_linkageBody->setParent( this );
|
|
|
|
|
m_linkageBody = std::move(linkageBody);
|
|
|
|
|
if( m_linkageBody ) m_linkageBody->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void LinkageSpecificationAST::setDeclaration( DeclarationAST::Node& decl )
|
|
|
|
|
{
|
|
|
|
|
m_declaration = decl;
|
|
|
|
|
if( m_declaration.get() ) m_declaration->setParent( this );
|
|
|
|
|
m_declaration = std::move(decl);
|
|
|
|
|
if( m_declaration ) m_declaration->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -299,7 +299,7 @@ TranslationUnitAST::TranslationUnitAST()
|
|
|
|
|
|
|
|
|
|
void TranslationUnitAST::addDeclaration( DeclarationAST::Node& ast )
|
|
|
|
|
{
|
|
|
|
|
if( !ast.get() )
|
|
|
|
|
if( !ast )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
ast->setParent( this );
|
|
|
|
@ -313,14 +313,14 @@ NamespaceAST::NamespaceAST()
|
|
|
|
|
|
|
|
|
|
void NamespaceAST::setNamespaceName( AST::Node& namespaceName )
|
|
|
|
|
{
|
|
|
|
|
m_namespaceName = namespaceName;
|
|
|
|
|
if( m_namespaceName.get() ) m_namespaceName->setParent( this );
|
|
|
|
|
m_namespaceName = std::move(namespaceName);
|
|
|
|
|
if( m_namespaceName ) m_namespaceName->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void NamespaceAST::setLinkageBody( LinkageBodyAST::Node& linkageBody )
|
|
|
|
|
{
|
|
|
|
|
m_linkageBody = linkageBody;
|
|
|
|
|
if( m_linkageBody.get() ) m_linkageBody->setParent( this );
|
|
|
|
|
m_linkageBody = std::move(linkageBody);
|
|
|
|
|
if( m_linkageBody ) m_linkageBody->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -331,14 +331,14 @@ NamespaceAliasAST::NamespaceAliasAST()
|
|
|
|
|
|
|
|
|
|
void NamespaceAliasAST::setNamespaceName( AST::Node& namespaceName )
|
|
|
|
|
{
|
|
|
|
|
m_namespaceName = namespaceName;
|
|
|
|
|
if( m_namespaceName.get() ) m_namespaceName->setParent( this );
|
|
|
|
|
m_namespaceName = std::move(namespaceName);
|
|
|
|
|
if( m_namespaceName ) m_namespaceName->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void NamespaceAliasAST::setAliasName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_aliasName = name;
|
|
|
|
|
if( m_aliasName.get() ) m_aliasName->setParent( this );
|
|
|
|
|
m_aliasName = std::move(name);
|
|
|
|
|
if( m_aliasName ) m_aliasName->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -348,14 +348,14 @@ UsingAST::UsingAST()
|
|
|
|
|
|
|
|
|
|
void UsingAST::setTypeName( AST::Node& typeName )
|
|
|
|
|
{
|
|
|
|
|
m_typeName = typeName;
|
|
|
|
|
if( m_typeName.get() ) m_typeName->setParent( this );
|
|
|
|
|
m_typeName = std::move(typeName);
|
|
|
|
|
if( m_typeName ) m_typeName->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void UsingAST::setName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -365,8 +365,8 @@ UsingDirectiveAST::UsingDirectiveAST()
|
|
|
|
|
|
|
|
|
|
void UsingDirectiveAST::setName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TypedefAST::TypedefAST()
|
|
|
|
@ -375,20 +375,20 @@ TypedefAST::TypedefAST()
|
|
|
|
|
|
|
|
|
|
void TypeSpecifierAST::setName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypedefAST::setTypeSpec( TypeSpecifierAST::Node& typeSpec )
|
|
|
|
|
{
|
|
|
|
|
m_typeSpec = typeSpec;
|
|
|
|
|
if( m_typeSpec.get() ) m_typeSpec->setParent( this );
|
|
|
|
|
m_typeSpec = std::move(typeSpec);
|
|
|
|
|
if( m_typeSpec ) m_typeSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypedefAST::setInitDeclaratorList( InitDeclaratorListAST::Node& initDeclaratorList )
|
|
|
|
|
{
|
|
|
|
|
m_initDeclaratorList = initDeclaratorList;
|
|
|
|
|
if( m_initDeclaratorList.get() ) m_initDeclaratorList->setParent( this );
|
|
|
|
|
m_initDeclaratorList = std::move(initDeclaratorList);
|
|
|
|
|
if( m_initDeclaratorList ) m_initDeclaratorList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -399,7 +399,7 @@ TemplateArgumentListAST::TemplateArgumentListAST()
|
|
|
|
|
|
|
|
|
|
void TemplateArgumentListAST::addArgument( AST::Node& arg )
|
|
|
|
|
{
|
|
|
|
|
if( !arg.get() )
|
|
|
|
|
if( !arg )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
arg->setParent( this );
|
|
|
|
@ -426,20 +426,20 @@ TemplateDeclarationAST::TemplateDeclarationAST()
|
|
|
|
|
|
|
|
|
|
void TemplateDeclarationAST::setExported( AST::Node& exported )
|
|
|
|
|
{
|
|
|
|
|
m_exported = exported;
|
|
|
|
|
if( m_exported.get() ) m_exported->setParent( this );
|
|
|
|
|
m_exported = std::move(exported);
|
|
|
|
|
if( m_exported ) m_exported->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TemplateDeclarationAST::setTemplateParameterList( TemplateParameterListAST::Node& templateParameterList )
|
|
|
|
|
{
|
|
|
|
|
m_templateParameterList = templateParameterList;
|
|
|
|
|
if( m_templateParameterList.get() ) m_templateParameterList->setParent( this );
|
|
|
|
|
m_templateParameterList = std::move(templateParameterList);
|
|
|
|
|
if( m_templateParameterList ) m_templateParameterList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TemplateDeclarationAST::setDeclaration( DeclarationAST::Node& declaration )
|
|
|
|
|
{
|
|
|
|
|
m_declaration = declaration;
|
|
|
|
|
if( m_declaration.get() ) m_declaration->setParent( this );
|
|
|
|
|
m_declaration = std::move(declaration);
|
|
|
|
|
if( m_declaration ) m_declaration->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -449,23 +449,23 @@ ClassOrNamespaceNameAST::ClassOrNamespaceNameAST()
|
|
|
|
|
|
|
|
|
|
void ClassOrNamespaceNameAST::setName( AST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ClassOrNamespaceNameAST::setTemplateArgumentList( TemplateArgumentListAST::Node& templateArgumentList )
|
|
|
|
|
{
|
|
|
|
|
m_templateArgumentList = templateArgumentList;
|
|
|
|
|
if( m_templateArgumentList.get() ) m_templateArgumentList->setParent( this );
|
|
|
|
|
m_templateArgumentList = std::move(templateArgumentList);
|
|
|
|
|
if( m_templateArgumentList ) m_templateArgumentList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TQString ClassOrNamespaceNameAST::text() const
|
|
|
|
|
{
|
|
|
|
|
if( !m_name.get() )
|
|
|
|
|
if( !m_name )
|
|
|
|
|
return TQString();
|
|
|
|
|
|
|
|
|
|
TQString str = m_name->text();
|
|
|
|
|
if( m_templateArgumentList.get() )
|
|
|
|
|
if( m_templateArgumentList )
|
|
|
|
|
str += TQString::fromLatin1("< ") + m_templateArgumentList->text() + TQString::fromLatin1(" >");
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
@ -478,27 +478,27 @@ TypeSpecifierAST::TypeSpecifierAST()
|
|
|
|
|
|
|
|
|
|
void TypeSpecifierAST::setCvQualify( GroupAST::Node& cvQualify )
|
|
|
|
|
{
|
|
|
|
|
m_cvQualify = cvQualify;
|
|
|
|
|
if( m_cvQualify.get() ) m_cvQualify->setParent( this );
|
|
|
|
|
m_cvQualify = std::move(cvQualify);
|
|
|
|
|
if( m_cvQualify ) m_cvQualify->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypeSpecifierAST::setCv2Qualify( GroupAST::Node& cv2Qualify )
|
|
|
|
|
{
|
|
|
|
|
m_cv2Qualify = cv2Qualify;
|
|
|
|
|
if( m_cv2Qualify.get() ) m_cv2Qualify->setParent( this );
|
|
|
|
|
m_cv2Qualify = std::move(cv2Qualify);
|
|
|
|
|
if( m_cv2Qualify ) m_cv2Qualify->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TQString TypeSpecifierAST::text() const
|
|
|
|
|
{
|
|
|
|
|
TQString str;
|
|
|
|
|
|
|
|
|
|
if( m_cvQualify.get() )
|
|
|
|
|
if( m_cvQualify )
|
|
|
|
|
str += m_cvQualify->text() + ' ';
|
|
|
|
|
|
|
|
|
|
if( m_name.get() )
|
|
|
|
|
if( m_name )
|
|
|
|
|
str += m_name->text();
|
|
|
|
|
|
|
|
|
|
if( m_cv2Qualify.get() )
|
|
|
|
|
if( m_cv2Qualify )
|
|
|
|
|
str += TQString(" ") + m_cv2Qualify->text();
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
@ -512,13 +512,13 @@ ClassSpecifierAST::ClassSpecifierAST()
|
|
|
|
|
|
|
|
|
|
void ClassSpecifierAST::setClassKey( AST::Node& classKey )
|
|
|
|
|
{
|
|
|
|
|
m_classKey = classKey;
|
|
|
|
|
if( m_classKey.get() ) m_classKey->setParent( this );
|
|
|
|
|
m_classKey = std::move(classKey);
|
|
|
|
|
if( m_classKey ) m_classKey->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ClassSpecifierAST::addDeclaration( DeclarationAST::Node& declaration )
|
|
|
|
|
{
|
|
|
|
|
if( !declaration.get() )
|
|
|
|
|
if( !declaration )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
declaration->setParent( this );
|
|
|
|
@ -527,8 +527,8 @@ void ClassSpecifierAST::addDeclaration( DeclarationAST::Node& declaration )
|
|
|
|
|
|
|
|
|
|
void ClassSpecifierAST::setBaseClause( BaseClauseAST::Node& baseClause )
|
|
|
|
|
{
|
|
|
|
|
m_baseClause = baseClause;
|
|
|
|
|
if( m_baseClause.get() ) m_baseClause->setParent( this );
|
|
|
|
|
m_baseClause = std::move(baseClause);
|
|
|
|
|
if( m_baseClause ) m_baseClause->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -539,7 +539,7 @@ EnumSpecifierAST::EnumSpecifierAST()
|
|
|
|
|
|
|
|
|
|
void EnumSpecifierAST::addEnumerator( EnumeratorAST::Node& enumerator )
|
|
|
|
|
{
|
|
|
|
|
if( !enumerator.get() )
|
|
|
|
|
if( !enumerator )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
enumerator->setParent( this );
|
|
|
|
@ -554,13 +554,13 @@ ElaboratedTypeSpecifierAST::ElaboratedTypeSpecifierAST()
|
|
|
|
|
|
|
|
|
|
void ElaboratedTypeSpecifierAST::setKind( AST::Node& kind )
|
|
|
|
|
{
|
|
|
|
|
m_kind = kind;
|
|
|
|
|
if( m_kind.get() ) m_kind->setParent( this );
|
|
|
|
|
m_kind = std::move(kind);
|
|
|
|
|
if( m_kind ) m_kind->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TQString ElaboratedTypeSpecifierAST::text() const
|
|
|
|
|
{
|
|
|
|
|
if( m_kind.get() )
|
|
|
|
|
if( m_kind )
|
|
|
|
|
return m_kind->text() + ' ' + TypeSpecifierAST::text();
|
|
|
|
|
|
|
|
|
|
return TypeSpecifierAST::text();
|
|
|
|
@ -578,14 +578,14 @@ EnumeratorAST::EnumeratorAST()
|
|
|
|
|
|
|
|
|
|
void EnumeratorAST::setId( AST::Node& id )
|
|
|
|
|
{
|
|
|
|
|
m_id = id;
|
|
|
|
|
if( m_id.get() ) m_id->setParent( this );
|
|
|
|
|
m_id = std::move(id);
|
|
|
|
|
if( m_id ) m_id->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void EnumeratorAST::setExpr( AST::Node& expr )
|
|
|
|
|
{
|
|
|
|
|
m_expr = expr;
|
|
|
|
|
if( m_expr.get() ) m_expr->setParent( this );
|
|
|
|
|
m_expr = std::move(expr);
|
|
|
|
|
if( m_expr ) m_expr->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -596,7 +596,7 @@ BaseClauseAST::BaseClauseAST()
|
|
|
|
|
|
|
|
|
|
void BaseClauseAST::addBaseSpecifier( BaseSpecifierAST::Node& baseSpecifier )
|
|
|
|
|
{
|
|
|
|
|
if( !baseSpecifier.get() )
|
|
|
|
|
if( !baseSpecifier )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
baseSpecifier->setParent( this );
|
|
|
|
@ -610,20 +610,20 @@ BaseSpecifierAST::BaseSpecifierAST()
|
|
|
|
|
|
|
|
|
|
void BaseSpecifierAST::setIsVirtual( AST::Node& isVirtual )
|
|
|
|
|
{
|
|
|
|
|
m_isVirtual = isVirtual;
|
|
|
|
|
if( m_isVirtual.get() ) m_isVirtual->setParent( this );
|
|
|
|
|
m_isVirtual = std::move(isVirtual);
|
|
|
|
|
if( m_isVirtual ) m_isVirtual->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void BaseSpecifierAST::setAccess( AST::Node& access )
|
|
|
|
|
{
|
|
|
|
|
m_access = access;
|
|
|
|
|
if( m_access.get() ) m_access->setParent( this );
|
|
|
|
|
m_access = std::move(access);
|
|
|
|
|
if( m_access ) m_access->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void BaseSpecifierAST::setName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------
|
|
|
|
@ -633,32 +633,32 @@ SimpleDeclarationAST::SimpleDeclarationAST()
|
|
|
|
|
|
|
|
|
|
void SimpleDeclarationAST::setFunctionSpecifier( GroupAST::Node& functionSpecifier )
|
|
|
|
|
{
|
|
|
|
|
m_functionSpecifier = functionSpecifier;
|
|
|
|
|
if( m_functionSpecifier.get() ) m_functionSpecifier->setParent( this );
|
|
|
|
|
m_functionSpecifier = std::move(functionSpecifier);
|
|
|
|
|
if( m_functionSpecifier ) m_functionSpecifier->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SimpleDeclarationAST::setStorageSpecifier( GroupAST::Node& storageSpecifier )
|
|
|
|
|
{
|
|
|
|
|
m_storageSpecifier = storageSpecifier;
|
|
|
|
|
if( m_storageSpecifier.get() ) m_storageSpecifier->setParent( this );
|
|
|
|
|
m_storageSpecifier = std::move(storageSpecifier);
|
|
|
|
|
if( m_storageSpecifier ) m_storageSpecifier->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SimpleDeclarationAST::setTypeSpec( TypeSpecifierAST::Node& typeSpec )
|
|
|
|
|
{
|
|
|
|
|
m_typeSpec = typeSpec;
|
|
|
|
|
if( m_typeSpec.get() ) m_typeSpec->setParent( this );
|
|
|
|
|
m_typeSpec = std::move(typeSpec);
|
|
|
|
|
if( m_typeSpec ) m_typeSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SimpleDeclarationAST::setInitDeclaratorList( InitDeclaratorListAST::Node& initDeclaratorList )
|
|
|
|
|
{
|
|
|
|
|
m_initDeclaratorList = initDeclaratorList;
|
|
|
|
|
if( m_initDeclaratorList.get() ) m_initDeclaratorList->setParent( this );
|
|
|
|
|
m_initDeclaratorList = std::move(initDeclaratorList);
|
|
|
|
|
if( m_initDeclaratorList ) m_initDeclaratorList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SimpleDeclarationAST::setWinDeclSpec( GroupAST::Node& winDeclSpec )
|
|
|
|
|
{
|
|
|
|
|
m_winDeclSpec = winDeclSpec;
|
|
|
|
|
if( m_winDeclSpec.get() ) m_winDeclSpec->setParent( this );
|
|
|
|
|
m_winDeclSpec = std::move(winDeclSpec);
|
|
|
|
|
if( m_winDeclSpec ) m_winDeclSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -670,7 +670,7 @@ InitDeclaratorListAST::InitDeclaratorListAST()
|
|
|
|
|
|
|
|
|
|
void InitDeclaratorListAST::addInitDeclarator( InitDeclaratorAST::Node& decl )
|
|
|
|
|
{
|
|
|
|
|
if( !decl.get() )
|
|
|
|
|
if( !decl )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
decl->setParent( this );
|
|
|
|
@ -686,52 +686,52 @@ DeclaratorAST::DeclaratorAST()
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setSubDeclarator( DeclaratorAST::Node& subDeclarator )
|
|
|
|
|
{
|
|
|
|
|
m_subDeclarator = subDeclarator;
|
|
|
|
|
if( m_subDeclarator.get() ) m_subDeclarator->setParent( this );
|
|
|
|
|
m_subDeclarator = std::move(subDeclarator);
|
|
|
|
|
if( m_subDeclarator ) m_subDeclarator->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setDeclaratorId( NameAST::Node& declaratorId )
|
|
|
|
|
{
|
|
|
|
|
m_declaratorId = declaratorId;
|
|
|
|
|
if( m_declaratorId.get() ) m_declaratorId->setParent( this );
|
|
|
|
|
m_declaratorId = std::move(declaratorId);
|
|
|
|
|
if( m_declaratorId ) m_declaratorId->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setBitfieldInitialization( AST::Node& bitfieldInitialization )
|
|
|
|
|
{
|
|
|
|
|
m_bitfieldInitialization = bitfieldInitialization;
|
|
|
|
|
if( m_bitfieldInitialization.get() ) m_bitfieldInitialization->setParent( this );
|
|
|
|
|
m_bitfieldInitialization = std::move(bitfieldInitialization);
|
|
|
|
|
if( m_bitfieldInitialization ) m_bitfieldInitialization->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::addArrayDimension( AST::Node& arrayDimension )
|
|
|
|
|
{
|
|
|
|
|
if( !arrayDimension.get() )
|
|
|
|
|
if( !arrayDimension )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
arrayDimension->setParent( this );
|
|
|
|
|
m_arrayDimensionList.append( arrayDimension.release() );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setParameterDeclarationClause( std::auto_ptr<class ParameterDeclarationClauseAST>& parameterDeclarationClause )
|
|
|
|
|
void DeclaratorAST::setParameterDeclarationClause( std::unique_ptr<class ParameterDeclarationClauseAST>& parameterDeclarationClause )
|
|
|
|
|
{
|
|
|
|
|
m_parameterDeclarationClause = parameterDeclarationClause;
|
|
|
|
|
if( m_parameterDeclarationClause.get() ) m_parameterDeclarationClause->setParent( this );
|
|
|
|
|
m_parameterDeclarationClause = std::move(parameterDeclarationClause);
|
|
|
|
|
if( m_parameterDeclarationClause ) m_parameterDeclarationClause->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setConstant( AST::Node& constant )
|
|
|
|
|
{
|
|
|
|
|
m_constant = constant;
|
|
|
|
|
if( m_constant.get() ) m_constant->setParent( this );
|
|
|
|
|
m_constant = std::move(constant);
|
|
|
|
|
if( m_constant ) m_constant->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::setExceptionSpecification( GroupAST::Node& exceptionSpecification )
|
|
|
|
|
{
|
|
|
|
|
m_exceptionSpecification = exceptionSpecification;
|
|
|
|
|
if( m_exceptionSpecification.get() ) m_exceptionSpecification->setParent( this );
|
|
|
|
|
m_exceptionSpecification = std::move(exceptionSpecification);
|
|
|
|
|
if( m_exceptionSpecification ) m_exceptionSpecification->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DeclaratorAST::addPtrOp( AST::Node& ptrOp )
|
|
|
|
|
{
|
|
|
|
|
if( !ptrOp.get() )
|
|
|
|
|
if( !ptrOp )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
ptrOp->setParent( this );
|
|
|
|
@ -745,14 +745,14 @@ InitDeclaratorAST::InitDeclaratorAST()
|
|
|
|
|
|
|
|
|
|
void InitDeclaratorAST::setDeclarator( DeclaratorAST::Node& declarator )
|
|
|
|
|
{
|
|
|
|
|
m_declarator = declarator;
|
|
|
|
|
if( m_declarator.get() ) m_declarator->setParent( this );
|
|
|
|
|
m_declarator = std::move(declarator);
|
|
|
|
|
if( m_declarator ) m_declarator->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void InitDeclaratorAST::setInitializer( AST::Node& initializer )
|
|
|
|
|
{
|
|
|
|
|
m_initializer = initializer;
|
|
|
|
|
if( m_initializer.get() ) m_initializer->setParent( this );
|
|
|
|
|
m_initializer = std::move(initializer);
|
|
|
|
|
if( m_initializer ) m_initializer->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -762,38 +762,38 @@ FunctionDefinitionAST::FunctionDefinitionAST()
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setFunctionSpecifier( GroupAST::Node& functionSpecifier )
|
|
|
|
|
{
|
|
|
|
|
m_functionSpecifier = functionSpecifier;
|
|
|
|
|
if( m_functionSpecifier.get() ) m_functionSpecifier->setParent( this );
|
|
|
|
|
m_functionSpecifier = std::move(functionSpecifier);
|
|
|
|
|
if( m_functionSpecifier ) m_functionSpecifier->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setStorageSpecifier( GroupAST::Node& storageSpecifier )
|
|
|
|
|
{
|
|
|
|
|
m_storageSpecifier = storageSpecifier;
|
|
|
|
|
if( m_storageSpecifier.get() ) m_storageSpecifier->setParent( this );
|
|
|
|
|
m_storageSpecifier = std::move(storageSpecifier);
|
|
|
|
|
if( m_storageSpecifier ) m_storageSpecifier->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setTypeSpec( TypeSpecifierAST::Node& typeSpec )
|
|
|
|
|
{
|
|
|
|
|
m_typeSpec = typeSpec;
|
|
|
|
|
if( m_typeSpec.get() ) m_typeSpec->setParent( this );
|
|
|
|
|
m_typeSpec = std::move(typeSpec);
|
|
|
|
|
if( m_typeSpec ) m_typeSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setInitDeclarator( InitDeclaratorAST::Node& initDeclarator )
|
|
|
|
|
{
|
|
|
|
|
m_initDeclarator = initDeclarator;
|
|
|
|
|
if( m_initDeclarator.get() ) m_initDeclarator->setParent( this );
|
|
|
|
|
m_initDeclarator = std::move(initDeclarator);
|
|
|
|
|
if( m_initDeclarator ) m_initDeclarator->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setFunctionBody( StatementListAST::Node& functionBody )
|
|
|
|
|
{
|
|
|
|
|
m_functionBody = functionBody;
|
|
|
|
|
if( m_functionBody.get() ) m_functionBody->setParent( this );
|
|
|
|
|
m_functionBody = std::move(functionBody);
|
|
|
|
|
if( m_functionBody ) m_functionBody->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FunctionDefinitionAST::setWinDeclSpec( GroupAST::Node& winDeclSpec )
|
|
|
|
|
{
|
|
|
|
|
m_winDeclSpec = winDeclSpec;
|
|
|
|
|
if( m_winDeclSpec.get() ) m_winDeclSpec->setParent( this );
|
|
|
|
|
m_winDeclSpec = std::move(winDeclSpec);
|
|
|
|
|
if( m_winDeclSpec ) m_winDeclSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -804,7 +804,7 @@ StatementListAST::StatementListAST()
|
|
|
|
|
|
|
|
|
|
void StatementListAST::addStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
if( !statement.get() )
|
|
|
|
|
if( !statement )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
statement->setParent( this );
|
|
|
|
@ -818,20 +818,20 @@ IfStatementAST::IfStatementAST()
|
|
|
|
|
|
|
|
|
|
void IfStatementAST::setCondition( ConditionAST::Node& condition )
|
|
|
|
|
{
|
|
|
|
|
m_condition = condition;
|
|
|
|
|
if( m_condition.get() ) m_condition->setParent( this );
|
|
|
|
|
m_condition = std::move(condition);
|
|
|
|
|
if( m_condition ) m_condition->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void IfStatementAST::setStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
m_statement = statement;
|
|
|
|
|
if( m_statement.get() ) m_statement->setParent( this );
|
|
|
|
|
m_statement = std::move(statement);
|
|
|
|
|
if( m_statement ) m_statement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void IfStatementAST::setElseStatement( StatementAST::Node& elseStatement )
|
|
|
|
|
{
|
|
|
|
|
m_elseStatement = elseStatement;
|
|
|
|
|
if( m_elseStatement.get() ) m_elseStatement->setParent( this );
|
|
|
|
|
m_elseStatement = std::move(elseStatement);
|
|
|
|
|
if( m_elseStatement ) m_elseStatement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -841,14 +841,14 @@ WhileStatementAST::WhileStatementAST()
|
|
|
|
|
|
|
|
|
|
void WhileStatementAST::setCondition( ConditionAST::Node& condition )
|
|
|
|
|
{
|
|
|
|
|
m_condition = condition;
|
|
|
|
|
if( m_condition.get() ) m_condition->setParent( this );
|
|
|
|
|
m_condition = std::move(condition);
|
|
|
|
|
if( m_condition ) m_condition->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void WhileStatementAST::setStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
m_statement = statement;
|
|
|
|
|
if( m_statement.get() ) m_statement->setParent( this );
|
|
|
|
|
m_statement = std::move(statement);
|
|
|
|
|
if( m_statement ) m_statement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -858,14 +858,14 @@ DoStatementAST::DoStatementAST()
|
|
|
|
|
|
|
|
|
|
void DoStatementAST::setCondition( ConditionAST::Node& condition )
|
|
|
|
|
{
|
|
|
|
|
m_condition = condition;
|
|
|
|
|
if( m_condition.get() ) m_condition->setParent( this );
|
|
|
|
|
m_condition = std::move(condition);
|
|
|
|
|
if( m_condition ) m_condition->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void DoStatementAST::setStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
m_statement = statement;
|
|
|
|
|
if( m_statement.get() ) m_statement->setParent( this );
|
|
|
|
|
m_statement = std::move(statement);
|
|
|
|
|
if( m_statement ) m_statement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -875,26 +875,26 @@ ForStatementAST::ForStatementAST()
|
|
|
|
|
|
|
|
|
|
void ForStatementAST::setCondition( ConditionAST::Node& condition )
|
|
|
|
|
{
|
|
|
|
|
m_condition = condition;
|
|
|
|
|
if( m_condition.get() ) m_condition->setParent( this );
|
|
|
|
|
m_condition = std::move(condition);
|
|
|
|
|
if( m_condition ) m_condition->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ForStatementAST::setExpression( AST::Node& expression )
|
|
|
|
|
{
|
|
|
|
|
m_expression = expression;
|
|
|
|
|
if( m_expression.get() ) m_expression->setParent( this );
|
|
|
|
|
m_expression = std::move(expression);
|
|
|
|
|
if( m_expression ) m_expression->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ForStatementAST::setStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
m_statement = statement;
|
|
|
|
|
if( m_statement.get() ) m_statement->setParent( this );
|
|
|
|
|
m_statement = std::move(statement);
|
|
|
|
|
if( m_statement ) m_statement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ForStatementAST::setInitStatement( StatementAST::Node& initStatement )
|
|
|
|
|
{
|
|
|
|
|
m_initStatement = initStatement;
|
|
|
|
|
if( m_initStatement.get() ) m_initStatement->setParent( this );
|
|
|
|
|
m_initStatement = std::move(initStatement);
|
|
|
|
|
if( m_initStatement ) m_initStatement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -904,14 +904,14 @@ SwitchStatementAST::SwitchStatementAST()
|
|
|
|
|
|
|
|
|
|
void SwitchStatementAST::setCondition( ConditionAST::Node& condition )
|
|
|
|
|
{
|
|
|
|
|
m_condition = condition;
|
|
|
|
|
if( m_condition.get() ) m_condition->setParent( this );
|
|
|
|
|
m_condition = std::move(condition);
|
|
|
|
|
if( m_condition ) m_condition->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SwitchStatementAST::setStatement( StatementAST::Node& statement )
|
|
|
|
|
{
|
|
|
|
|
m_statement = statement;
|
|
|
|
|
if( m_statement.get() ) m_statement->setParent( this );
|
|
|
|
|
m_statement = std::move(statement);
|
|
|
|
|
if( m_statement ) m_statement->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -921,8 +921,8 @@ DeclarationStatementAST::DeclarationStatementAST()
|
|
|
|
|
|
|
|
|
|
void DeclarationStatementAST::setDeclaration( DeclarationAST::Node& declaration )
|
|
|
|
|
{
|
|
|
|
|
m_declaration = declaration;
|
|
|
|
|
if( m_declaration.get() ) m_declaration->setParent( this );
|
|
|
|
|
m_declaration = std::move(declaration);
|
|
|
|
|
if( m_declaration ) m_declaration->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -932,8 +932,8 @@ ExpressionStatementAST::ExpressionStatementAST()
|
|
|
|
|
|
|
|
|
|
void ExpressionStatementAST::setExpression( AST::Node& expression )
|
|
|
|
|
{
|
|
|
|
|
m_expression = expression;
|
|
|
|
|
if( m_expression.get() ) m_expression->setParent( this );
|
|
|
|
|
m_expression = std::move(expression);
|
|
|
|
|
if( m_expression ) m_expression->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -944,32 +944,32 @@ ParameterDeclarationAST::ParameterDeclarationAST()
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationAST::setTypeSpec( TypeSpecifierAST::Node& typeSpec )
|
|
|
|
|
{
|
|
|
|
|
m_typeSpec = typeSpec;
|
|
|
|
|
if( m_typeSpec.get() ) m_typeSpec->setParent( this );
|
|
|
|
|
m_typeSpec = std::move(typeSpec);
|
|
|
|
|
if( m_typeSpec ) m_typeSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationAST::setDeclarator( DeclaratorAST::Node& declarator )
|
|
|
|
|
{
|
|
|
|
|
m_declarator = declarator;
|
|
|
|
|
if( m_declarator.get() ) m_declarator->setParent( this );
|
|
|
|
|
m_declarator = std::move(declarator);
|
|
|
|
|
if( m_declarator ) m_declarator->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationAST::setExpression( AST::Node& expression )
|
|
|
|
|
{
|
|
|
|
|
m_expression = expression;
|
|
|
|
|
if( m_expression.get() ) m_expression->setParent( this );
|
|
|
|
|
m_expression = std::move(expression);
|
|
|
|
|
if( m_expression ) m_expression->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TQString ParameterDeclarationAST::text() const
|
|
|
|
|
{
|
|
|
|
|
TQString str;
|
|
|
|
|
if( m_typeSpec.get() )
|
|
|
|
|
if( m_typeSpec )
|
|
|
|
|
str += m_typeSpec->text() + ' ';
|
|
|
|
|
|
|
|
|
|
if( m_declarator.get() )
|
|
|
|
|
if( m_declarator )
|
|
|
|
|
str += m_declarator->text();
|
|
|
|
|
|
|
|
|
|
if( m_expression.get() )
|
|
|
|
|
if( m_expression )
|
|
|
|
|
str += TQString( " = " ) + m_expression->text();
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
@ -983,7 +983,7 @@ ParameterDeclarationListAST::ParameterDeclarationListAST()
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationListAST::addParameter( ParameterDeclarationAST::Node& parameter )
|
|
|
|
|
{
|
|
|
|
|
if( !parameter.get() )
|
|
|
|
|
if( !parameter )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
parameter->setParent( this );
|
|
|
|
@ -1011,24 +1011,24 @@ ParameterDeclarationClauseAST::ParameterDeclarationClauseAST()
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationClauseAST::setParameterDeclarationList( ParameterDeclarationListAST::Node& parameterDeclarationList )
|
|
|
|
|
{
|
|
|
|
|
m_parameterDeclarationList = parameterDeclarationList;
|
|
|
|
|
if( m_parameterDeclarationList.get() ) m_parameterDeclarationList->setParent( this );
|
|
|
|
|
m_parameterDeclarationList = std::move(parameterDeclarationList);
|
|
|
|
|
if( m_parameterDeclarationList ) m_parameterDeclarationList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ParameterDeclarationClauseAST::setEllipsis( AST::Node& ellipsis )
|
|
|
|
|
{
|
|
|
|
|
m_ellipsis = ellipsis;
|
|
|
|
|
if( m_ellipsis.get() ) m_ellipsis->setParent( this );
|
|
|
|
|
m_ellipsis = std::move(ellipsis);
|
|
|
|
|
if( m_ellipsis ) m_ellipsis->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TQString ParameterDeclarationClauseAST::text() const
|
|
|
|
|
{
|
|
|
|
|
TQString str;
|
|
|
|
|
|
|
|
|
|
if( m_parameterDeclarationList.get() )
|
|
|
|
|
if( m_parameterDeclarationList )
|
|
|
|
|
str += m_parameterDeclarationList->text();
|
|
|
|
|
|
|
|
|
|
if( m_ellipsis.get() )
|
|
|
|
|
if( m_ellipsis )
|
|
|
|
|
str += " ...";
|
|
|
|
|
|
|
|
|
|
return str;
|
|
|
|
@ -1043,7 +1043,7 @@ GroupAST::GroupAST()
|
|
|
|
|
|
|
|
|
|
void GroupAST::addNode( AST::Node& node )
|
|
|
|
|
{
|
|
|
|
|
if( !node.get() )
|
|
|
|
|
if( !node )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
node->setParent( this );
|
|
|
|
@ -1071,7 +1071,7 @@ AccessDeclarationAST::AccessDeclarationAST()
|
|
|
|
|
|
|
|
|
|
void AccessDeclarationAST::addAccess( AST::Node& access )
|
|
|
|
|
{
|
|
|
|
|
if( !access.get() )
|
|
|
|
|
if( !access )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
access->setParent( this );
|
|
|
|
@ -1098,26 +1098,26 @@ TypeParameterAST::TypeParameterAST()
|
|
|
|
|
|
|
|
|
|
void TypeParameterAST::setKind( AST::Node& kind )
|
|
|
|
|
{
|
|
|
|
|
m_kind = kind;
|
|
|
|
|
if( m_kind.get() ) m_kind->setParent( this );
|
|
|
|
|
m_kind = std::move(kind);
|
|
|
|
|
if( m_kind ) m_kind->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypeParameterAST::setTemplateParameterList( std::auto_ptr<class TemplateParameterListAST>& templateParameterList )
|
|
|
|
|
void TypeParameterAST::setTemplateParameterList( std::unique_ptr<class TemplateParameterListAST>& templateParameterList )
|
|
|
|
|
{
|
|
|
|
|
m_templateParameterList = templateParameterList;
|
|
|
|
|
if( m_templateParameterList.get() ) m_templateParameterList->setParent( this );
|
|
|
|
|
m_templateParameterList = std::move(templateParameterList);
|
|
|
|
|
if( m_templateParameterList ) m_templateParameterList->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypeParameterAST::setName( NameAST::Node& name )
|
|
|
|
|
{
|
|
|
|
|
m_name = name;
|
|
|
|
|
if( m_name.get() ) m_name->setParent( this );
|
|
|
|
|
m_name = std::move(name);
|
|
|
|
|
if( m_name ) m_name->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TypeParameterAST::setTypeId( AST::Node& typeId )
|
|
|
|
|
{
|
|
|
|
|
m_typeId = typeId;
|
|
|
|
|
if( m_typeId.get() ) m_typeId->setParent( this );
|
|
|
|
|
m_typeId = std::move(typeId);
|
|
|
|
|
if( m_typeId ) m_typeId->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -1127,14 +1127,14 @@ TemplateParameterAST::TemplateParameterAST()
|
|
|
|
|
|
|
|
|
|
void TemplateParameterAST::setTypeParameter( TypeParameterAST::Node& typeParameter )
|
|
|
|
|
{
|
|
|
|
|
m_typeParameter = typeParameter;
|
|
|
|
|
if( m_typeParameter.get() ) m_typeParameter->setParent( this );
|
|
|
|
|
m_typeParameter = std::move(typeParameter);
|
|
|
|
|
if( m_typeParameter ) m_typeParameter->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void TemplateParameterAST::setTypeValueParameter( ParameterDeclarationAST::Node& typeValueParameter )
|
|
|
|
|
{
|
|
|
|
|
m_typeValueParameter = typeValueParameter;
|
|
|
|
|
if( m_typeValueParameter.get() ) m_typeValueParameter->setParent( this );
|
|
|
|
|
m_typeValueParameter = std::move(typeValueParameter);
|
|
|
|
|
if( m_typeValueParameter ) m_typeValueParameter->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
|
|
@ -1145,7 +1145,7 @@ TemplateParameterListAST::TemplateParameterListAST()
|
|
|
|
|
|
|
|
|
|
void TemplateParameterListAST::addTemplateParameter( TemplateParameterAST::Node& templateParameter )
|
|
|
|
|
{
|
|
|
|
|
if( !templateParameter.get() )
|
|
|
|
|
if( !templateParameter )
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
templateParameter->setParent( this );
|
|
|
|
@ -1159,25 +1159,25 @@ ConditionAST::ConditionAST()
|
|
|
|
|
|
|
|
|
|
void ConditionAST::setTypeSpec( TypeSpecifierAST::Node& typeSpec )
|
|
|
|
|
{
|
|
|
|
|
m_typeSpec = typeSpec;
|
|
|
|
|
if( m_typeSpec.get() ) m_typeSpec->setParent( this );
|
|
|
|
|
m_typeSpec = std::move(typeSpec);
|
|
|
|
|
if( m_typeSpec ) m_typeSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ConditionAST::setDeclarator( DeclaratorAST::Node& declarator )
|
|
|
|
|
{
|
|
|
|
|
m_declarator = declarator;
|
|
|
|
|
if( m_declarator.get() ) m_declarator->setParent( this );
|
|
|
|
|
m_declarator = std::move(declarator);
|
|
|
|
|
if( m_declarator ) m_declarator->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ConditionAST::setExpression( AST::Node& expression )
|
|
|
|
|
{
|
|
|
|
|
m_expression = expression;
|
|
|
|
|
if( m_expression.get() ) m_expression->setParent( this );
|
|
|
|
|
m_expression = std::move(expression);
|
|
|
|
|
if( m_expression ) m_expression->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ClassSpecifierAST::setWinDeclSpec( GroupAST::Node & winDeclSpec )
|
|
|
|
|
{
|
|
|
|
|
m_winDeclSpec = winDeclSpec;
|
|
|
|
|
if( m_winDeclSpec.get() ) m_winDeclSpec->setParent( this );
|
|
|
|
|
m_winDeclSpec = std::move(winDeclSpec);
|
|
|
|
|
if( m_winDeclSpec ) m_winDeclSpec->setParent( this );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|