[Lldb-commits] [PATCH] D131459: Move FormattersMatchCandidate flags to a struct.
Jorge Gorbe Moya via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Mon Aug 8 18:09:08 PDT 2022
jgorbe created this revision.
Herald added a project: All.
jgorbe requested review of this revision.
Herald added a project: LLDB.
Move FormattersMatchCandidate flags to a struct.
This removes some error-prone repetition in
FormatManager::GetPossibleMatches, where the same three boolean flags
are passed in a row multiple times as arguments to recursive calls to
GetPossibleMatches.
Instead of:
// same flags, but with did_strip_typedef set to true.
GetPossibleMatches(..., did_strip_ptr, did_strip_ref, true);
we can now say
GetPossibleMatches(..., current_flags.WithStrippedTypedef());
which hopefully makes the intent clearer, and more readable in case we
add another flag.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D131459
Files:
lldb/include/lldb/DataFormatters/FormatClasses.h
lldb/include/lldb/DataFormatters/FormatManager.h
lldb/source/DataFormatters/FormatManager.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D131459.451010.patch
Type: text/x-patch
Size: 9960 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20220809/17f259e6/attachment.bin>
More information about the lldb-commits
mailing list