[PATCH] D27837: Add fix-it notes to the nullability consistency warning
Alex Lorenz via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 16 02:26:05 PST 2016
arphaman added inline comments.
================
Comment at: lib/Sema/SemaType.cpp:3491
+/// taking into account whitespace before and after.
+static FixItHint fixItNullability(Sema &S, SourceLocation pointerLoc,
+ NullabilityKind nullability) {
----------------
NIT: I noticed that you don't follow LLVM's naming style for variables here (the parameter and variable names should start with an upper case letter). I realise that there are some functions around the new functions in this file that don't follow this style, so this might be better for local consistency, but it would be nice if the new code follows LLVM's style.
================
Comment at: lib/Sema/SemaType.cpp:3495
+
+ SmallString<32> insertionTextBuf{" "};
+ insertionTextBuf += getNullabilitySpelling(nullability);
----------------
Another NIT: I think it's better to avoid the braced initializer here, and use `SmallString<32> insertionTextBuf = " "` instead
Repository:
rL LLVM
https://reviews.llvm.org/D27837
More information about the cfe-commits
mailing list