reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

tools/clang/lib/Format/ContinuationIndenter.cpp
   77   if (!Tok.MatchingParen)
   79   FormatToken *End = Tok.MatchingParen;
   96     if (End->Next->MatchingParen &&
   97         End->Next->MatchingParen->isOneOf(
   99       const ParenState *State = FindParenState(End->Next->MatchingParen);
  644       (Previous.MatchingParen &&
  645        (Previous.TotalLength - Previous.MatchingParen->TotalLength > 10)))
  720     if (Previous.MatchingParen) {
  721       const FormatToken *Next = Previous.MatchingParen->getNextNonComment();
  833     if (Current.is(tok::r_brace) && Current.MatchingParen &&
  836         !Current.MatchingParen->Children.empty()) {
  952     if (Current.MatchingParen &&
  953         Current.MatchingParen->BlockKind == BK_BracedInit)
 1311   if (Current.MatchingParen && Current.BlockKind == BK_Block) {
 1331     bool EndsInComma = Current.MatchingParen &&
 1332                        Current.MatchingParen->Previous &&
 1333                        Current.MatchingParen->Previous->is(tok::comma);
 1359         Current.MatchingParen &&
 1360         Current.MatchingParen->getPreviousNonComment() &&
 1361         Current.MatchingParen->getPreviousNonComment()->is(tok::comma);
 1383     if (Current.is(TT_ObjCMethodExpr) && Current.MatchingParen) {
 1394              Tok && Tok != Current.MatchingParen; Tok = Tok->Next) {
 1451   if (State.Stack.back().BreakBeforeParameter && Current.MatchingParen &&
 1452       Current.MatchingParen->Previous) {
 1453     const FormatToken &CurrentScopeOpener = *Current.MatchingParen->Previous;
 1455         CurrentScopeOpener.MatchingParen) {
 1731     Tok = Tok->MatchingParen;
tools/clang/lib/Format/FormatToken.cpp
  109   while (State.NextToken != LBrace->MatchingParen) {
  153   if (!Token->MatchingParen ||
  196       ItemEnd = Token->MatchingParen;
  207         ItemEnd = Token->MatchingParen->Previous;
  222     if (ItemEnd->getNextNonComment() == Token->MatchingParen)
tools/clang/lib/Format/FormatToken.h
  532     return MatchingParen && MatchingParen->opensBlockOrBlockTypeList(Style);
  532     return MatchingParen && MatchingParen->opensBlockOrBlockTypeList(Style);
tools/clang/lib/Format/TokenAnnotator.cpp
   49       Left->Previous->MatchingParen &&
   50       Left->Previous->MatchingParen->is(TT_TemplateOpener))
   51     Left = Left->Previous->MatchingParen;
   55          Left->Previous->MatchingParen &&
   56          Left->Previous->MatchingParen->is(TT_LambdaLSquare);
   86           (!Previous.Previous->MatchingParen ||
   87            !Previous.Previous->MatchingParen->is(TT_OverloadedOperatorLParen)))
  111         Left->MatchingParen = CurrentToken;
  112         CurrentToken->MatchingParen = Left;
  225     } else if (Left->Previous && Left->Previous->MatchingParen &&
  226                Left->Previous->MatchingParen->is(TT_ObjCBlockLParen)) {
  287         Left->MatchingParen = CurrentToken;
  288         CurrentToken->MatchingParen = Left;
  600         Left->MatchingParen = CurrentToken;
  601         CurrentToken->MatchingParen = Left;
  675           Left->MatchingParen = CurrentToken;
  676           CurrentToken->MatchingParen = Left;
  878           Tok->Previous->MatchingParen &&
  879           Tok->Previous->MatchingParen->is(TT_OverloadedOperatorLParen)) {
  881         Tok->Previous->MatchingParen->Type = TT_OverloadedOperator;
 1234     CurrentToken->MatchingParen = nullptr;
 1311             Previous = Previous->MatchingParen;
 1441       if (Current.MatchingParen && Current.Next &&
 1446         if (FormatToken *AfterParen = Current.MatchingParen->Next) {
 1449             if (FormatToken *BeforeParen = Current.MatchingParen->Previous)
 1489                Current.Previous->MatchingParen &&
 1490                Current.Previous->MatchingParen->Previous &&
 1491                Current.Previous->MatchingParen->Previous->is(
 1553       return PreviousNotConst && PreviousNotConst->MatchingParen &&
 1554              PreviousNotConst->MatchingParen->Previous &&
 1555              PreviousNotConst->MatchingParen->Previous->isNot(tok::period) &&
 1556              PreviousNotConst->MatchingParen->Previous->isNot(tok::kw_template);
 1558     if (PreviousNotConst->is(tok::r_paren) && PreviousNotConst->MatchingParen &&
 1559         PreviousNotConst->MatchingParen->Previous &&
 1560         PreviousNotConst->MatchingParen->Previous->is(tok::kw_decltype))
 1576     if (Tok.Previous == Tok.MatchingParen || !Tok.Next || !Tok.MatchingParen)
 1576     if (Tok.Previous == Tok.MatchingParen || !Tok.Next || !Tok.MatchingParen)
 1579     FormatToken *LeftOfParens = Tok.MatchingParen->getPreviousNonComment();
 1584         if (!LeftOfParens->MatchingParen ||
 1585             !LeftOfParens->MatchingParen->Previous)
 1587         LeftOfParens = LeftOfParens->MatchingParen->Previous;
 1644     for (const FormatToken *Token = Tok.MatchingParen->Next; Token != &Tok;
 1666     for (FormatToken *Prev = Tok.Previous; Prev != Tok.MatchingParen;
 1709     if (PrevToken->is(tok::r_paren) && PrevToken->MatchingParen) {
 1711           PrevToken->MatchingParen->getPreviousNonComment();
 1854            (Current->MatchingParen || Current->is(TT_TemplateString))) ||
 2112         Next = Next->MatchingParen;
 2132   if (!Next || !Next->is(tok::l_paren) || !Next->MatchingParen)
 2137   if (Next->Next == Next->MatchingParen)
 2140   if (Next->MatchingParen->Next &&
 2141       Next->MatchingParen->Next->is(TT_PointerOrReference))
 2143   for (const FormatToken *Tok = Next->Next; Tok && Tok != Next->MatchingParen;
 2145     if (Tok->isOneOf(tok::l_paren, TT_TemplateOpener) && Tok->MatchingParen) {
 2146       Tok = Tok->MatchingParen;
 2284     if (Current->MatchingParen &&
 2285         Current->MatchingParen->opensBlockOrBlockTypeList(Style)) {
 2531             (Left.MatchingParen && Left.MatchingParen->is(TT_CastRParen)))
 2531             (Left.MatchingParen && Left.MatchingParen->is(TT_CastRParen)))
 2537     bool IsLightweightGeneric = Right.MatchingParen &&
 2538                                 Right.MatchingParen->Next &&
 2539                                 Right.MatchingParen->Next->is(tok::colon);
 2573       if (!Left.MatchingParen)
 2576           Left.MatchingParen->getPreviousNonComment();
 2624     return Right.MatchingParen &&
 2625            ((Right.MatchingParen->is(TT_ArrayInitializerLSquare) &&
 2626              SpaceRequiredForArrayInitializerLSquare(*Right.MatchingParen,
 2629              Right.MatchingParen->isOneOf(TT_ArraySubscriptLSquare,
 2632             Right.MatchingParen->is(TT_AttributeParen));
 2642       (Right.is(tok::r_brace) && Right.MatchingParen &&
 2643        Right.MatchingParen->BlockKind != BK_Block))
 2665              (Left.is(tok::r_square) && Left.MatchingParen &&
 2666               Left.MatchingParen->is(TT_LambdaLSquare))) &&
 2684   if (Left.is(TT_TemplateCloser) && Left.MatchingParen &&
 2685       Left.MatchingParen->Previous &&
 2686       (Left.MatchingParen->Previous->is(tok::period) ||
 2687        Left.MatchingParen->Previous->is(tok::coloncolon)))
 2697   if (Right.is(tok::r_brace) && Right.MatchingParen &&
 2698       Right.MatchingParen->endsSequence(TT_DictLiteral, tok::at))
 2737     if (Left.MatchingParen &&
 2738         Left.MatchingParen->is(TT_ProtoExtensionLSquare) &&
 2764         Right.MatchingParen) {
 2765       const FormatToken *Next = Right.MatchingParen->getNextNonComment();
 2975       Left.MatchingParen && Left.MatchingParen->is(TT_OverloadedOperatorLParen))
 2975       Left.MatchingParen && Left.MatchingParen->is(TT_OverloadedOperatorLParen))
 3052         Left.BlockKind != BK_Block && Left.MatchingParen)
 3053       BeforeClosingBrace = Left.MatchingParen->Previous;
 3054     else if (Right.MatchingParen &&
 3055              (Right.MatchingParen->isOneOf(tok::l_brace,
 3058                Right.MatchingParen->is(tok::l_paren))))
 3078       Right.Previous->MatchingParen &&
 3079       Right.Previous->MatchingParen->NestingLevel == 0 &&
 3120     if (Left.MatchingParen && Left.MatchingParen->Next &&
 3120     if (Left.MatchingParen && Left.MatchingParen->Next &&
 3121         Left.MatchingParen->Next->isOneOf(tok::comma, tok::r_paren) &&
 3426   if (Right.is(tok::r_square) && Right.MatchingParen &&
 3427       Right.MatchingParen->is(TT_ProtoExtensionLSquare))
 3464   if (Right.is(tok::r_square) && Right.MatchingParen &&
 3465       Right.MatchingParen->is(TT_LambdaLSquare))
 3471     return Right.MatchingParen && Right.MatchingParen->BlockKind == BK_Block;
 3471     return Right.MatchingParen && Right.MatchingParen->BlockKind == BK_Block;
tools/clang/lib/Format/WhitespaceManager.cpp
  492     if (Current->is(tok::r_paren) && Current->MatchingParen) {
  493       Current = Current->MatchingParen->Previous;