Page MenuHomePhabricator

Please use GitHub pull requests for new patches. Phabricator shutdown timeline

CJ-Johnson (CJ Johnson)
User

Projects

User does not belong to any projects.

User Details

User Since
Jan 2 2020, 8:06 AM (194 w, 3 d)

Recent Activity

Apr 28 2022

CJ-Johnson accepted D124164: [include-cleaner] Include-cleaner library structure, and simplistic AST walking..
Apr 28 2022, 1:53 PM · Restricted Project, Restricted Project, Restricted Project

Jan 20 2022

CJ-Johnson committed rGa5684114445a: [clang-tidy] Update bugprone-stringview-nullptr to consistently prefer the… (authored by CJ-Johnson).
[clang-tidy] Update bugprone-stringview-nullptr to consistently prefer the…
Jan 20 2022, 3:09 PM
CJ-Johnson closed D117840: [clang-tidy] Update bugprone-stringview-nullptr to consistently prefer the empty string when passing arguments to constructors/functions.
Jan 20 2022, 3:08 PM · Restricted Project
CJ-Johnson requested review of D117840: [clang-tidy] Update bugprone-stringview-nullptr to consistently prefer the empty string when passing arguments to constructors/functions.
Jan 20 2022, 3:07 PM · Restricted Project

Jan 12 2022

CJ-Johnson committed rG81c330e23dd4: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to… (authored by CJ-Johnson).
Filter string_view from the nullptr diagnosis of bugprone-string-constructor to…
Jan 12 2022, 2:05 PM
CJ-Johnson closed D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.
Jan 12 2022, 2:05 PM · Restricted Project
CJ-Johnson committed rG7e29da875ca9: Add support for return values in bugprone-stringview-nullptr (authored by CJ-Johnson).
Add support for return values in bugprone-stringview-nullptr
Jan 12 2022, 1:57 PM
CJ-Johnson closed D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Jan 12 2022, 1:57 PM · Restricted Project
CJ-Johnson added inline comments to D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Jan 12 2022, 1:48 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Add code comment about the choice of hasAnyArgument

Jan 12 2022, 1:47 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Nits

Jan 12 2022, 10:33 AM · Restricted Project
CJ-Johnson added a comment to D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.

I'm in 2 minds about this. This diagnostic is a good fit for this warning and shouldn't be removed. Likewise duplicate diagnostics from different checks is annoying. Maybe a better path forward would be to suppress the diagnostic if the bugprone-stringview-nullptr check is enabled. These kinds of intercheck dependencies are found in modernize-prefer-member-init check IIRC. You can just copy the impl from there.

Jan 12 2022, 10:22 AM · Restricted Project
CJ-Johnson updated the diff for D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.

Only filter out basic_string_view when bugprone-stringview-nullptr is enabled

Jan 12 2022, 10:21 AM · Restricted Project

Jan 11 2022

CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Nit

Jan 11 2022, 5:22 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Rebase on head

Jan 11 2022, 5:13 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Nit

Jan 11 2022, 5:13 PM · Restricted Project
CJ-Johnson retitled D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view from Update bugprone-stringview-nullptr to prefer the empty string for most edits to Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Jan 11 2022, 5:12 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Switching back to original plan of adding support for return statements

Jan 11 2022, 5:01 PM · Restricted Project

Dec 9 2021

CJ-Johnson requested review of D115452: Prevent abseil-cleanup-ctad check from stomping on surrounding context.
Dec 9 2021, 9:15 AM · Restricted Project

Dec 7 2021

CJ-Johnson retitled D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view from Add support for return values in bugprone-stringview-nullptr to Update bugprone-stringview-nullptr to prefer the empty string for most edits.
Dec 7 2021, 9:22 AM · Restricted Project

Dec 6 2021

CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Switch to using empty string edits everywhere except equality comparison

Dec 6 2021, 1:19 PM · Restricted Project

Dec 5 2021

CJ-Johnson added inline comments to D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Dec 5 2021, 1:49 PM · Restricted Project
CJ-Johnson updated the summary of D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Dec 5 2021, 1:48 PM · Restricted Project
CJ-Johnson added inline comments to D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Dec 5 2021, 1:46 PM · Restricted Project
CJ-Johnson updated the diff for D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.

Add missing tests for function arguments and fix incorrect warning message for static_cast cases

Dec 5 2021, 1:45 PM · Restricted Project
CJ-Johnson added inline comments to D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Dec 5 2021, 11:15 AM · Restricted Project
CJ-Johnson requested review of D115121: Update bugprone-stringview-nullptr to support return statements and constructors for any T which accepts basic_string_view.
Dec 5 2021, 11:13 AM · Restricted Project

Dec 1 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Delete non-functional test cases (which were previously commented out)

Dec 1 2021, 2:29 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add missing comment lines

Dec 1 2021, 9:54 AM · Restricted Project
CJ-Johnson updated the summary of D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.
Dec 1 2021, 8:35 AM · Restricted Project
CJ-Johnson updated the diff for D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.

Switch to early return for the filter

Dec 1 2021, 8:33 AM · Restricted Project

Nov 30 2021

CJ-Johnson added a comment to D113148: Add new clang-tidy check for string_view(nullptr).

Pinging this thread with https://reviews.llvm.org/D113148

Nov 30 2021, 3:22 PM · Restricted Project
CJ-Johnson updated the summary of D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.
Nov 30 2021, 3:21 PM · Restricted Project
CJ-Johnson updated the summary of D113148: Add new clang-tidy check for string_view(nullptr).
Nov 30 2021, 3:21 PM · Restricted Project
CJ-Johnson requested review of D114823: Filter string_view from the nullptr diagnosis of bugprone-string-constructor to prevent duplicate warnings with bugprone-stringview-nullptr.
Nov 30 2021, 3:19 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Rebase on head

Nov 30 2021, 2:16 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Address nits

Nov 30 2021, 2:15 PM · Restricted Project

Nov 22 2021

CJ-Johnson added a comment to D113148: Add new clang-tidy check for string_view(nullptr).

Thank you all for the feedback! Would it be ok to proceed with removing the nullptr checking for basic_string_view in bugprone-string-constructor, as Alex indicated?

Nov 22 2021, 10:45 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Rebase on head

Nov 22 2021, 10:42 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Address reviewer comments

Nov 22 2021, 10:42 AM · Restricted Project

Nov 12 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Address review comments from Yitzie

Nov 12 2021, 11:42 AM · Restricted Project
CJ-Johnson added inline comments to D113148: Add new clang-tidy check for string_view(nullptr).
Nov 12 2021, 11:09 AM · Restricted Project

Nov 8 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add missing test cases

Nov 8 2021, 2:35 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add additional tests for sv.empty() cases to ensure parens are removed where appropriate

Nov 8 2021, 11:23 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Rebase on head

Nov 8 2021, 9:28 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add missing newline

Nov 8 2021, 9:24 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add AST matcher support and tests for {{}} case where a null pointer is implicitly created

Nov 8 2021, 9:23 AM · Restricted Project
CJ-Johnson added inline comments to D113148: Add new clang-tidy check for string_view(nullptr).
Nov 8 2021, 9:20 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Update test file to use truncated messages

Nov 8 2021, 7:34 AM · Restricted Project
CJ-Johnson updated the diff for D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..

Fix documentation nit

Nov 8 2021, 7:06 AM · Restricted Project
CJ-Johnson updated the diff for D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..

Address nits and update the absl::Cleanup stub to be accurate with the real interface (with associated changes to the AST matcher)

Nov 8 2021, 7:04 AM · Restricted Project
CJ-Johnson added a comment to D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..

Thanks for the review! I'll apply the same fixes to the string_view diff as well

Nov 8 2021, 7:03 AM · Restricted Project

Nov 5 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

nits

Nov 5 2021, 10:55 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Remove double brackets for list initialization and use default initialization to avoid most vexing parse

Nov 5 2021, 10:47 AM · Restricted Project

Nov 4 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Change static_cast suggested edit to use parens instead of braces

Nov 4 2021, 3:50 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Fix spelling error

Nov 4 2021, 3:20 PM · Restricted Project
CJ-Johnson added a comment to D113148: Add new clang-tidy check for string_view(nullptr).

Thanks for the additional info, @aaron.ballman! I had not considered the issues with duplicate warnings. I agree that it would be annoying for users. That being the case, the second option ("remove the string_view nullptr checking functionality from bugprone-string-constructor so it only lives in the new check") sounds the most appealing to me, personally.

Nov 4 2021, 3:15 PM · Restricted Project
CJ-Johnson added a comment to D113148: Add new clang-tidy check for string_view(nullptr).

Generally speaking, we prefer to improve the existing checks. I think bugprone-string-constructor would probably be a better place for the constructor-related functionality. But that still means we don't have a good place for things like the assignment and comparison functionality, and it seems more useful to keep all of the string_view-with-nullptr logic in one place. That said, we should be careful we're not too onerous when users enable all bugprone checks together.

Nov 4 2021, 9:14 AM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Remove trailing whitespace

Nov 4 2021, 9:09 AM · Restricted Project
CJ-Johnson updated the diff for D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..

Add trailing newline

Nov 4 2021, 9:06 AM · Restricted Project
CJ-Johnson updated the diff for D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..

Remove unwanted changes

Nov 4 2021, 9:06 AM · Restricted Project
CJ-Johnson requested review of D113195: [clang-tidy] Add check for initialization of `absl::Cleanup`..
Nov 4 2021, 9:02 AM · Restricted Project
CJ-Johnson added a comment to D113148: Add new clang-tidy check for string_view(nullptr).

This seems to be an existing check. Have you compared it with bugprone-string-constructor?

Nov 4 2021, 6:38 AM · Restricted Project

Nov 3 2021

CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Add missing newline

Nov 3 2021, 3:16 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Remove mistaken changes

Nov 3 2021, 3:14 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Remove mistaken changes

Nov 3 2021, 3:13 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Rebase on head

Nov 3 2021, 3:09 PM · Restricted Project
CJ-Johnson updated the diff for D113148: Add new clang-tidy check for string_view(nullptr).

Update docs to reflect current state

Nov 3 2021, 2:58 PM · Restricted Project
CJ-Johnson requested review of D113148: Add new clang-tidy check for string_view(nullptr).
Nov 3 2021, 2:47 PM · Restricted Project

Sep 30 2021

CJ-Johnson abandoned D110842: [NFC][AMDGPU] Improve cost model tests coverage..
Sep 30 2021, 8:27 AM · Restricted Project
CJ-Johnson requested review of D110842: [NFC][AMDGPU] Improve cost model tests coverage..
Sep 30 2021, 8:26 AM · Restricted Project

Sep 27 2021

CJ-Johnson abandoned D110574: Test diff, please ignore.
Sep 27 2021, 12:17 PM · Restricted Project
CJ-Johnson requested review of D110574: Test diff, please ignore.
Sep 27 2021, 12:11 PM · Restricted Project
CJ-Johnson abandoned D110559: Test branch commit, please ignore.
Sep 27 2021, 9:28 AM · Restricted Project
CJ-Johnson abandoned D110562: Test diff, please ignore. Trying for a third time!.
Sep 27 2021, 9:27 AM · Restricted Project
CJ-Johnson updated the diff for D110562: Test diff, please ignore. Trying for a third time!.

Now with code! Will it run the tests?

Sep 27 2021, 9:25 AM · Restricted Project
CJ-Johnson updated the diff for D110562: Test diff, please ignore. Trying for a third time!.

Amended commit??

Sep 27 2021, 9:20 AM · Restricted Project
CJ-Johnson added inline comments to D110562: Test diff, please ignore. Trying for a third time!.
Sep 27 2021, 9:20 AM · Restricted Project
CJ-Johnson requested review of D110562: Test diff, please ignore. Trying for a third time!.
Sep 27 2021, 9:19 AM · Restricted Project
CJ-Johnson updated the diff for D110559: Test branch commit, please ignore.

Trying again but with a branch to see if that helps

Sep 27 2021, 8:30 AM · Restricted Project
CJ-Johnson added inline comments to D110559: Test branch commit, please ignore.
Sep 27 2021, 8:28 AM · Restricted Project
CJ-Johnson requested review of D110559: Test branch commit, please ignore.
Sep 27 2021, 8:27 AM · Restricted Project
CJ-Johnson abandoned D110554: Test arc diff message, please ignore.
Sep 27 2021, 8:16 AM · Restricted Project
CJ-Johnson updated the diff for D110554: Test arc diff message, please ignore.

Test update message, please ignore

Sep 27 2021, 8:09 AM · Restricted Project
CJ-Johnson added a comment to D110554: Test arc diff message, please ignore.

Test top-level comment, please ignore

Sep 27 2021, 8:06 AM · Restricted Project
CJ-Johnson requested review of D110554: Test arc diff message, please ignore.
Sep 27 2021, 8:04 AM · Restricted Project

Nov 16 2020

CJ-Johnson added a comment to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..

Please modify the commit subject and add a proper message.

Nov 16 2020, 3:35 PM · Restricted Project, Restricted Project
CJ-Johnson retitled D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments. from [CodeGen] Apply 'nonnull' to 'this' pointer arguments. to [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 16 2020, 3:35 PM · Restricted Project, Restricted Project
CJ-Johnson updated the diff for D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 16 2020, 2:49 PM · Restricted Project, Restricted Project

Nov 7 2020

CJ-Johnson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 7 2020, 9:05 AM · Restricted Project, Restricted Project
CJ-Johnson updated the diff for D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 7 2020, 9:04 AM · Restricted Project, Restricted Project

Nov 2 2020

CJ-Johnson added a comment to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..

Thanks! We should also have a test for the behavior when targeting the MS ABI, where we sometimes don't emit the nonnull dereferenceable because the "this" pointer might actually point outside the object, but otherwise I think this is ready to go.

Please can you also put together a patch for the release notes? This seems worth mentioning there.

Nov 2 2020, 3:12 AM · Restricted Project, Restricted Project
CJ-Johnson updated the diff for D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 2 2020, 3:11 AM · Restricted Project, Restricted Project

Oct 31 2020

CJ-Johnson added a comment to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..

The new tests can be found in this-nonnull.cpp: https://reviews.llvm.org/differential/changeset/?ref=2242268

Oct 31 2020, 11:18 AM · Restricted Project, Restricted Project
CJ-Johnson updated the diff for D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Oct 31 2020, 11:17 AM · Restricted Project, Restricted Project
CJ-Johnson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Oct 31 2020, 9:49 AM · Restricted Project, Restricted Project

Oct 12 2020

CJ-Johnson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Oct 12 2020, 11:57 AM · Restricted Project, Restricted Project
CJ-Johnson updated the diff for D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..

Apply dereferenceable even if null is a valid address

Oct 12 2020, 11:53 AM · Restricted Project, Restricted Project
CJ-Johnson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Oct 12 2020, 11:29 AM · Restricted Project, Restricted Project
CJ-Johnson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Oct 12 2020, 11:24 AM · Restricted Project, Restricted Project