Lines Matching full:lines

153     // adaptStartOfLine will break after lines starting with /** if the comment  in getCommentSplit()
347 // Following lines are indented by the width of the brace and space if any. in BreakableStringLiteralUsingOperators()
416 unsigned BreakableComment::getLineCount() const { return Lines.size(); } in getLineCount()
422 // Don't break lines matching the comment pragmas regex. in getSplit()
452 // Lines starting with '@' or '\' commonly have special meaning. in mayReflowContent()
453 // Lines starting with '-', '-#', '+' or '*' are bulleted/numbered lists. in mayReflowContent()
493 .split(Lines, UseCRLF ? "\r\n" : "\n"); in BreakableBlockComment()
496 Content.resize(Lines.size()); in BreakableBlockComment()
497 Content[0] = Lines[0]; in BreakableBlockComment()
498 ContentColumn.resize(Lines.size()); in BreakableBlockComment()
501 Tokens.resize(Lines.size()); in BreakableBlockComment()
502 for (size_t i = 1; i < Lines.size(); ++i) in BreakableBlockComment()
514 if (Lines.size() >= 2 && Content[1].starts_with("**") && in BreakableBlockComment()
520 if (Lines.size() == 1 && !FirstInLine) { in BreakableBlockComment()
523 // lines with the first one. in BreakableBlockComment()
543 for (size_t i = 1, e = Lines.size(); i < e; ++i) { in BreakableBlockComment()
550 // Align the star in the last '*/' with the stars on the previous lines. in BreakableBlockComment()
554 // For all other lines, set the start column to 0 if they're empty, so in BreakableBlockComment()
563 // For all other lines, adjust the line to exclude the star and in BreakableBlockComment()
580 if ((Lines[0] == "*" || Lines[0].starts_with("* ")) && Lines.size() > 1) { in BreakableBlockComment()
583 } else if (Lines[0].starts_with("* ") && Lines.size() == 1) { in BreakableBlockComment()
589 encoding::columnWidthWithTabs(Lines[0], ContentColumn[0], in BreakableBlockComment()
599 for (size_t i = 0; i < Lines.size(); ++i) { in BreakableBlockComment()
602 << "IN=" << (Content[i].data() - Lines[i].data()) << "\n"; in BreakableBlockComment()
610 // Don't break lines matching the comment pragmas regex. in getSplit()
625 size_t EndOfPreviousLine = Lines[LineIndex - 1].size(); in adjustWhitespace()
626 if (InPPDirective && Lines[LineIndex - 1].ends_with("\\")) in adjustWhitespace()
631 Lines[LineIndex - 1].find_last_not_of(Blanks, EndOfPreviousLine); in adjustWhitespace()
637 size_t StartOfLine = Lines[LineIndex].find_first_not_of(Blanks); in adjustWhitespace()
639 StartOfLine = Lines[LineIndex].size(); in adjustWhitespace()
641 StringRef Whitespace = Lines[LineIndex].substr(0, StartOfLine); in adjustWhitespace()
642 // Adjust Lines to only contain relevant text. in adjustWhitespace()
644 Content[LineIndex - 1].data() - Lines[LineIndex - 1].data(); in adjustWhitespace()
645 Content[LineIndex - 1] = Lines[LineIndex - 1].substr( in adjustWhitespace()
647 Content[LineIndex] = Lines[LineIndex].substr(StartOfLine); in adjustWhitespace()
649 // Adjust the start column uniformly across all lines. in adjustWhitespace()
670 if (LineIndex + 1 == Lines.size()) { in getRemainingLength()
675 bool HasDecoration = Lines[LineIndex].ltrim().starts_with(Decoration); in getRemainingLength()
718 // the lines except for the last one, where the star in "*/" acts as a in insertBreak()
721 if (LineIndex + 1 == Lines.size() && in insertBreak()
765 Lines[0].substr(1).find_first_not_of(Blanks) != StringRef::npos; in introducesBreakBeforeToken()
797 size_t BreakLength = Lines[0].substr(1).find_first_not_of(Blanks); in adaptStartOfLine()
809 if (LineIndex + 1 == Lines.size()) { in adaptStartOfLine()
816 // For other empty lines, if we do have a decoration, adapt it to not in adaptStartOfLine()
856 if (Lines[LineIndex].ltrim(Blanks).starts_with("*")) in mayReflow()
857 IndentContent = Lines[LineIndex].ltrim(Blanks).substr(1); in mayReflow()
872 // applied in all following lines in BreakableLineCommentSection()
881 size_t FirstLineIndex = Lines.size(); in BreakableLineCommentSection()
882 TokenText.split(Lines, "\n"); in BreakableLineCommentSection()
883 Content.resize(Lines.size()); in BreakableLineCommentSection()
884 ContentColumn.resize(Lines.size()); in BreakableLineCommentSection()
885 PrefixSpaceChange.resize(Lines.size()); in BreakableLineCommentSection()
886 Tokens.resize(Lines.size()); in BreakableLineCommentSection()
887 Prefix.resize(Lines.size()); in BreakableLineCommentSection()
888 OriginalPrefix.resize(Lines.size()); in BreakableLineCommentSection()
889 for (size_t i = FirstLineIndex, e = Lines.size(); i < e; ++i) { in BreakableLineCommentSection()
890 Lines[i] = Lines[i].ltrim(Blanks); in BreakableLineCommentSection()
891 StringRef IndentPrefix = getLineCommentIndentPrefix(Lines[i], Style); in BreakableLineCommentSection()
898 assert(Lines[i].size() > IndentPrefix.size()); in BreakableLineCommentSection()
899 const char FirstCommentChar = Lines[i][IndentPrefix.size()]; in BreakableLineCommentSection()
903 Lines[i].substr(IndentPrefix.size(), FirstCharByteSize), in BreakableLineCommentSection()
923 // are to be added or removed, all lines after that just get only the in BreakableLineCommentSection()
929 if (SpacesInPrefix < Minimum && Lines[i].size() > IndentPrefix.size() && in BreakableLineCommentSection()
941 if (Lines[i].size() != IndentPrefix.size()) { in BreakableLineCommentSection()
949 assert(Lines[i].size() > IndentPrefix.size()); in BreakableLineCommentSection()
950 const auto FirstNonSpace = Lines[i][IndentPrefix.size()]; in BreakableLineCommentSection()
977 Content[i] = Lines[i].substr(IndentPrefix.size()); in BreakableLineCommentSection()
995 // would split the contents of the enum into two unwrapped lines in this in BreakableLineCommentSection()
1075 unsigned Offset = Lines[LineIndex - 1].data() + in reflow()
1076 Lines[LineIndex - 1].size() - in reflow()
1081 Lines[LineIndex].data() - tokenAt(LineIndex).TokenText.data() - Offset; in reflow()
1092 Lines[LineIndex].data() - tokenAt(LineIndex).TokenText.data(); in reflow()
1094 Content[LineIndex].data() - Lines[LineIndex].data(); in reflow()
1120 (Content[LineIndex].data() - Lines[LineIndex].data()) + in adaptStartOfLine()
1155 if (Lines[LineIndex].starts_with("//")) in mayReflow()
1156 IndentContent = Lines[LineIndex].substr(2); in mayReflow()