As part of using inclusive language within the llvm project,
migrate away from the use of blacklist and whitelist.
This commit is contained in:
parent
efb328f674
commit
2db1d75396
|
@ -226,7 +226,7 @@ def get_member_types_for_offset(value_type, offset, member_list):
|
||||||
def append_regex_callback(option, opt, value, parser):
|
def append_regex_callback(option, opt, value, parser):
|
||||||
try:
|
try:
|
||||||
ivar_regex = re.compile(value)
|
ivar_regex = re.compile(value)
|
||||||
parser.values.ivar_regex_blacklist.append(ivar_regex)
|
parser.values.ivar_regex_exclusions.append(ivar_regex)
|
||||||
except:
|
except:
|
||||||
print('error: an exception was thrown when compiling the ivar regular expression for "%s"' % value)
|
print('error: an exception was thrown when compiling the ivar regular expression for "%s"' % value)
|
||||||
|
|
||||||
|
@ -287,7 +287,7 @@ def add_common_options(parser):
|
||||||
type='string',
|
type='string',
|
||||||
action='callback',
|
action='callback',
|
||||||
callback=append_regex_callback,
|
callback=append_regex_callback,
|
||||||
dest='ivar_regex_blacklist',
|
dest='ivar_regex_exclusions',
|
||||||
default=[],
|
default=[],
|
||||||
help='specify one or more regular expressions used to backlist any matches that are in ivars')
|
help='specify one or more regular expressions used to backlist any matches that are in ivars')
|
||||||
parser.add_option(
|
parser.add_option(
|
||||||
|
@ -773,8 +773,8 @@ def display_match_results(
|
||||||
member_path += '.'
|
member_path += '.'
|
||||||
member_path += member_name
|
member_path += member_name
|
||||||
if member_path:
|
if member_path:
|
||||||
if options.ivar_regex_blacklist:
|
if options.ivar_regex_exclusions:
|
||||||
for ivar_regex in options.ivar_regex_blacklist:
|
for ivar_regex in options.ivar_regex_exclusions:
|
||||||
if ivar_regex.match(
|
if ivar_regex.match(
|
||||||
member_path):
|
member_path):
|
||||||
print_entry = False
|
print_entry = False
|
||||||
|
|
Loading…
Reference in New Issue