llvm/clang/unittests/Tooling/Syntax/BuildTreeTest.cpp

//===- BuildTreeTest.cpp --------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
//
// This file tests the syntax tree generation from the ClangAST.
//
//===----------------------------------------------------------------------===//

#include "TreeTestBase.h"

usingnamespaceclang;
usingnamespaceclang::syntax;

namespace {

class BuildSyntaxTreeTest : public SyntaxTreeTest {};

INSTANTIATE_TEST_SUITE_P();

TEST_P(BuildSyntaxTreeTest, Simple) {}

TEST_P(BuildSyntaxTreeTest, SimpleVariable) {}

TEST_P(BuildSyntaxTreeTest, SimpleFunction) {}

TEST_P(BuildSyntaxTreeTest, Simple_BackslashInsideToken) {}

TEST_P(BuildSyntaxTreeTest, If) {}

TEST_P(BuildSyntaxTreeTest, IfDecl) {}

TEST_P(BuildSyntaxTreeTest, For) {}

TEST_P(BuildSyntaxTreeTest, RangeBasedFor) {}

TEST_P(BuildSyntaxTreeTest, DeclarationStatement) {}

TEST_P(BuildSyntaxTreeTest, Switch) {}

TEST_P(BuildSyntaxTreeTest, While) {}

TEST_P(BuildSyntaxTreeTest, UnhandledStatement) {}

TEST_P(BuildSyntaxTreeTest, Expressions) {}

TEST_P(BuildSyntaxTreeTest, ConditionalOperator) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_Identifier) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_OperatorFunctionId) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_ConversionFunctionId) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_LiteralOperatorId) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_Destructor) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_DecltypeDestructor) {}

TEST_P(BuildSyntaxTreeTest, UnqualifiedId_TemplateId) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_NamespaceSpecifier) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_TemplateSpecifier) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_DecltypeSpecifier) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_OptionalTemplateKw) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_Complex) {}

TEST_P(BuildSyntaxTreeTest, QualifiedId_DependentType) {}

TEST_P(BuildSyntaxTreeTest, This_Simple) {}

TEST_P(BuildSyntaxTreeTest, This_ExplicitMemberAccess) {}

TEST_P(BuildSyntaxTreeTest, This_ImplicitMemberAccess) {}

TEST_P(BuildSyntaxTreeTest, ParenExpr) {}

TEST_P(BuildSyntaxTreeTest, UserDefinedLiteral_Char) {}

TEST_P(BuildSyntaxTreeTest, UserDefinedLiteral_String) {}

TEST_P(BuildSyntaxTreeTest, UserDefinedLiteral_Integer) {}

TEST_P(BuildSyntaxTreeTest, UserDefinedLiteral_Float) {}

TEST_P(BuildSyntaxTreeTest, IntegerLiteral_LongLong) {}

TEST_P(BuildSyntaxTreeTest, IntegerLiteral_Binary) {}

TEST_P(BuildSyntaxTreeTest, IntegerLiteral_WithDigitSeparators) {}

TEST_P(BuildSyntaxTreeTest, CharacterLiteral) {}

TEST_P(BuildSyntaxTreeTest, CharacterLiteral_Utf) {}

TEST_P(BuildSyntaxTreeTest, CharacterLiteral_Utf8) {}

TEST_P(BuildSyntaxTreeTest, FloatingLiteral) {}

TEST_P(BuildSyntaxTreeTest, FloatingLiteral_Hexadecimal) {}

TEST_P(BuildSyntaxTreeTest, StringLiteral) {}

TEST_P(BuildSyntaxTreeTest, StringLiteral_Utf) {}

TEST_P(BuildSyntaxTreeTest, StringLiteral_Raw) {}

TEST_P(BuildSyntaxTreeTest, BoolLiteral) {}

TEST_P(BuildSyntaxTreeTest, CxxNullPtrLiteral) {}

TEST_P(BuildSyntaxTreeTest, PostfixUnaryOperator) {}

TEST_P(BuildSyntaxTreeTest, PrefixUnaryOperator) {}

TEST_P(BuildSyntaxTreeTest, PrefixUnaryOperatorCxx) {}

TEST_P(BuildSyntaxTreeTest, BinaryOperator) {}

TEST_P(BuildSyntaxTreeTest, BinaryOperatorCxx) {}

TEST_P(BuildSyntaxTreeTest, BinaryOperator_NestedWithParenthesis) {}

TEST_P(BuildSyntaxTreeTest, BinaryOperator_Associativity) {}

TEST_P(BuildSyntaxTreeTest, BinaryOperator_Precedence) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_Assignment) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_Plus) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_Less) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_LeftShift) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_Comma) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_PointerToMember) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_Negation) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_AddressOf) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_PrefixIncrement) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperator_PostfixIncrement) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_SimpleWithDot) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_StaticDataMember) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_SimpleWithArrow) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_Chaining) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_OperatorFunction) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_VariableTemplate) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_FunctionTemplate) {}

TEST_P(BuildSyntaxTreeTest,
       MemberExpression_FunctionTemplateWithTemplateKeyword) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_WithQualifier) {}

TEST_P(BuildSyntaxTreeTest, MemberExpression_Complex) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_Member) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_OperatorParens) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_OperatorParensChaining) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_MemberWithThis) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_FunctionPointer) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Callee_MemberFunctionPointer) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_Zero) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_One) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_Multiple) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_Assignment) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_BracedInitList_Empty) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_BracedInitList_Simple) {}

TEST_P(BuildSyntaxTreeTest,
       CallExpression_Arguments_BracedInitList_Designated) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_Arguments_ParameterPack) {}

TEST_P(BuildSyntaxTreeTest, CallExpression_DefaultArguments) {}

TEST_P(BuildSyntaxTreeTest, MultipleDeclaratorsGrouping) {}

TEST_P(BuildSyntaxTreeTest, MultipleDeclaratorsGroupingTypedef) {}

TEST_P(BuildSyntaxTreeTest, MultipleDeclaratorsInsideStatement) {}

TEST_P(BuildSyntaxTreeTest, SizeTTypedef) {}

TEST_P(BuildSyntaxTreeTest, Namespace_Nested) {}

TEST_P(BuildSyntaxTreeTest, Namespace_NestedDefinition) {}

TEST_P(BuildSyntaxTreeTest, Namespace_Unnamed) {}

TEST_P(BuildSyntaxTreeTest, Namespace_Alias) {}

TEST_P(BuildSyntaxTreeTest, UsingDirective) {}

TEST_P(BuildSyntaxTreeTest, UsingDeclaration_Namespace) {}

TEST_P(BuildSyntaxTreeTest, UsingDeclaration_ClassMember) {}

TEST_P(BuildSyntaxTreeTest, UsingTypeAlias) {}

TEST_P(BuildSyntaxTreeTest, FreeStandingClass_ForwardDeclaration) {}

TEST_P(BuildSyntaxTreeTest, FreeStandingClasses_Definition) {}

TEST_P(BuildSyntaxTreeTest, StaticMemberFunction) {}

TEST_P(BuildSyntaxTreeTest, OutOfLineMemberFunctionDefinition) {}

TEST_P(BuildSyntaxTreeTest, ConversionMemberFunction) {}

TEST_P(BuildSyntaxTreeTest, LiteralOperatorDeclaration) {}

TEST_P(BuildSyntaxTreeTest, NumericLiteralOperatorTemplateDeclaration) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperatorDeclaration) {}

TEST_P(BuildSyntaxTreeTest, OverloadedOperatorFriendDeclaration) {}

TEST_P(BuildSyntaxTreeTest, ClassTemplateDeclaration) {}

TEST_P(BuildSyntaxTreeTest, FunctionTemplateDeclaration) {}

TEST_P(BuildSyntaxTreeTest, VariableTemplateDeclaration) {}

TEST_P(BuildSyntaxTreeTest, StaticMemberFunctionTemplate) {}

TEST_P(BuildSyntaxTreeTest, NestedTemplates) {}

TEST_P(BuildSyntaxTreeTest, NestedTemplatesInNamespace) {}

TEST_P(BuildSyntaxTreeTest, ClassTemplate_MemberClassDefinition) {}

TEST_P(BuildSyntaxTreeTest, ExplicitClassTemplateInstantiation_Definition) {}

TEST_P(BuildSyntaxTreeTest, ExplicitClassTemplateInstantiation_Declaration) {}

TEST_P(BuildSyntaxTreeTest, ClassTemplateSpecialization_Partial) {}

TEST_P(BuildSyntaxTreeTest, ClassTemplateSpecialization_Full) {}

TEST_P(BuildSyntaxTreeTest, EmptyDeclaration) {}

TEST_P(BuildSyntaxTreeTest, StaticAssert) {}

TEST_P(BuildSyntaxTreeTest, StaticAssert_WithoutMessage) {}

TEST_P(BuildSyntaxTreeTest, ExternC) {}

TEST_P(BuildSyntaxTreeTest, Macro_ObjectLike_Leaf) {}

TEST_P(BuildSyntaxTreeTest, Macro_ObjectLike_MatchTree) {}

TEST_P(BuildSyntaxTreeTest, Macro_ObjectLike_MismatchTree) {}

TEST_P(BuildSyntaxTreeTest, Macro_FunctionLike_ModifiableArguments) {}

TEST_P(BuildSyntaxTreeTest, Macro_FunctionLike_MismatchTree) {}

TEST_P(BuildSyntaxTreeTest, Macro_FunctionLike_Variadic) {}

TEST_P(BuildSyntaxTreeTest, InitDeclarator_Equal) {}

TEST_P(BuildSyntaxTreeTest, InitDeclarator_Brace) {}

TEST_P(BuildSyntaxTreeTest, InitDeclarator_EqualBrace) {}

TEST_P(BuildSyntaxTreeTest, InitDeclarator_Paren) {}

TEST_P(BuildSyntaxTreeTest, InitDeclarator_Paren_DefaultArguments) {}

TEST_P(BuildSyntaxTreeTest, ImplicitConversion_Argument) {}

TEST_P(BuildSyntaxTreeTest, ImplicitConversion_Return) {}

TEST_P(BuildSyntaxTreeTest, ConstructorCall_ZeroArguments) {}

TEST_P(BuildSyntaxTreeTest, ConstructorCall_OneArgument) {}

TEST_P(BuildSyntaxTreeTest, ConstructorCall_MultipleArguments) {}

TEST_P(BuildSyntaxTreeTest, ConstructorCall_DefaultArguments) {}

TEST_P(BuildSyntaxTreeTest, TypeConversion_FunctionalNotation) {}

TEST_P(BuildSyntaxTreeTest, ArrayDeclarator_Simple) {}

TEST_P(BuildSyntaxTreeTest, ArrayDeclarator_Multidimensional) {}

TEST_P(BuildSyntaxTreeTest, ArrayDeclarator_UnknownBound) {}

TEST_P(BuildSyntaxTreeTest, ArrayDeclarator_Static) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InFreeFunctions_Empty) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InFreeFunctions_Named) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InFreeFunctions_Unnamed) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InFreeFunctions_Default_One) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InFreeFunctions_Default_Multiple) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InVariadicFunctionTemplate_ParameterPack) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InVariadicFunctionTemplate_NamedParameterPack) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InFreeFunctions_VariadicArguments) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InFreeFunctions_Cxx_CvQualifiers) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InFreeFunctions_Cxx_Ref) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InFreeFunctions_Cxx11_RefRef) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InMemberFunctions_Simple) {}

TEST_P(BuildSyntaxTreeTest,
       ParametersAndQualifiers_InMemberFunctions_CvQualifiers) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InMemberFunctions_Ref) {}

TEST_P(BuildSyntaxTreeTest, ParametersAndQualifiers_InMemberFunctions_RefRef) {}

TEST_P(BuildSyntaxTreeTest, TrailingReturn) {}

TEST_P(BuildSyntaxTreeTest, DynamicExceptionSpecification) {}

TEST_P(BuildSyntaxTreeTest, NoexceptExceptionSpecification) {}

TEST_P(BuildSyntaxTreeTest, DeclaratorsInParentheses) {}

TEST_P(BuildSyntaxTreeTest, Declaration_ConstVolatileQualifiers_SimpleConst) {}

TEST_P(BuildSyntaxTreeTest, Declaration_ConstVolatileQualifiers_MultipleConst) {}

TEST_P(BuildSyntaxTreeTest,
       Declaration_ConstVolatileQualifiers_ConstAndVolatile) {}

TEST_P(BuildSyntaxTreeTest, RangesOfDeclaratorsWithTrailingReturnTypes) {}

TEST_P(BuildSyntaxTreeTest, MemberPointers) {}

TEST_P(BuildSyntaxTreeTest, MemberFunctionPointer) {}

TEST_P(BuildSyntaxTreeTest, ComplexDeclarator) {}

TEST_P(BuildSyntaxTreeTest, ComplexDeclarator2) {}

} // namespace