Skip to content

Commit 01983b4

Browse files
committed
fix some remaining formatting issues
1 parent 5956fc2 commit 01983b4

File tree

5 files changed

+20
-12
lines changed

5 files changed

+20
-12
lines changed

clang/include/clang/Lex/Preprocessor.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2446,8 +2446,7 @@ class Preprocessor {
24462446
/// reference is for system \#include's or not (i.e. using <> instead of "").
24472447
OptionalFileEntryRef
24482448
LookupEmbedFile(SourceLocation FilenameLoc, StringRef Filename, bool isAngled,
2449-
bool OpenFile,
2450-
const FileEntry *LookupFromFile = nullptr,
2449+
bool OpenFile, const FileEntry *LookupFromFile = nullptr,
24512450
SmallVectorImpl<char> *SearchPath = nullptr,
24522451
SmallVectorImpl<char> *RelativePath = nullptr);
24532452

clang/lib/Frontend/DependencyGraph.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ class DependencyGraphCallback : public PPCallbacks {
5353
DependencyGraphCallback(const Preprocessor *_PP, StringRef OutputFile,
5454
StringRef SysRoot,
5555
DirectiveBehavior Action = IgnoreEmbed)
56-
: PP(_PP), OutputFile(OutputFile.str()), SysRoot(SysRoot.str()) { }
56+
: PP(_PP), OutputFile(OutputFile.str()), SysRoot(SysRoot.str()) {}
5757

5858
void InclusionDirective(SourceLocation HashLoc, const Token &IncludeTok,
5959
StringRef FileName, bool IsAngled,

clang/lib/Frontend/Rewrite/InclusionRewriter.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -463,11 +463,11 @@ void InclusionRewriter::Process(FileID FileId,
463463
// Add line marker to indicate we're returning from an included
464464
// file.
465465
LineInfoExtra = " 2";
466-
}
467-
// fix up lineinfo (since commented out directive changed line
468-
// numbers) for inclusions that were skipped due to header guards
469-
WriteLineInfo(FileName, Line, FileType, LineInfoExtra);
470-
break;
466+
}
467+
// fix up lineinfo (since commented out directive changed line
468+
// numbers) for inclusions that were skipped due to header guards
469+
WriteLineInfo(FileName, Line, FileType, LineInfoExtra);
470+
break;
471471
}
472472
case tok::pp_pragma: {
473473
StringRef Identifier = NextIdentifierName(RawLex, RawToken);

clang/lib/Lex/PPDirectives.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4193,16 +4193,16 @@ void Preprocessor::HandleEmbedDirective(SourceLocation HashLoc, Token &EmbedTok,
41934193
if (Callbacks && Callbacks->EmbedFileNotFound(OriginalFilename)) {
41944194
return;
41954195
}
4196-
Diag(FilenameTok, diag::err_pp_file_not_found)
4197-
<< Filename;
4196+
Diag(FilenameTok, diag::err_pp_file_not_found) << Filename;
41984197
return;
41994198
}
42004199
std::optional<int64_t> MaybeSignedLimit{};
42014200
if (Params.MaybeLimitParam) {
42024201
MaybeSignedLimit = static_cast<int64_t>(Params.MaybeLimitParam->Limit);
42034202
}
4204-
llvm::ErrorOr<std::unique_ptr<llvm::MemoryBuffer>> MaybeFile = getFileManager().getBufferForFile(
4205-
*MaybeFileRef, false, false, MaybeSignedLimit);
4203+
llvm::ErrorOr<std::unique_ptr<llvm::MemoryBuffer>> MaybeFile =
4204+
getFileManager().getBufferForFile(*MaybeFileRef, false, false,
4205+
MaybeSignedLimit);
42064206
if (!MaybeFile) {
42074207
// could not find file
42084208
Diag(FilenameTok, diag::err_cannot_open_file)

clang/lib/Parse/ParseExpr.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -742,6 +742,8 @@ class CastExpressionIdValidator final : public CorrectionCandidateCallback {
742742
};
743743
}
744744

745+
// clang-format off
746+
745747
/// Parse a cast-expression, or, if \pisUnaryExpression is true, parse
746748
/// a unary-expression.
747749
///
@@ -926,6 +928,9 @@ class CastExpressionIdValidator final : public CorrectionCandidateCallback {
926928
/// '__is_rvalue_expr'
927929
/// \endverbatim
928930
///
931+
932+
// clang-format on
933+
929934
ExprResult Parser::ParseCastExpression(CastParseKind ParseKind,
930935
bool isAddressOfOperand,
931936
bool &NotCastExpr,
@@ -2564,6 +2569,8 @@ ExprResult Parser::ParseUnaryExprOrTypeTraitExpression() {
25642569
return Operand;
25652570
}
25662571

2572+
// clang-format off
2573+
25672574
/// ParseBuiltinPrimaryExpression
25682575
///
25692576
/// \verbatim
@@ -2588,6 +2595,8 @@ ExprResult Parser::ParseUnaryExprOrTypeTraitExpression() {
25882595
/// [GNU] offsetof-member-designator '.' identifier
25892596
/// [GNU] offsetof-member-designator '[' expression ']'
25902597
/// \endverbatim
2598+
2599+
// clang-format on
25912600
ExprResult Parser::ParseBuiltinPrimaryExpression() {
25922601
ExprResult Res;
25932602
const IdentifierInfo *BuiltinII = Tok.getIdentifierInfo();

0 commit comments

Comments
 (0)