Functions | |
def | find_closing_mustache (contents, initial_depth) |
def | is_a_define_statement (match, body) |
def | update_file (contents, namespaces) |
Variables | |
tuple | _CONFIGURATION = (Config(['src/core', 'test/core'], ['grpc_core']),) |
string | _TEST |
string | _TEST_EXPECTED |
list | changed = [] |
Config = collections.namedtuple('Config', ['dirs', 'namespaces']) | |
contents = f.read() | |
def | output = update_file(_TEST, ['foo']) |
path = os.path.join(root, file) | |
def | updated = update_file(contents, config.namespaces) |
def check_redundant_namespace_qualifiers.find_closing_mustache | ( | contents, | |
initial_depth | |||
) |
Find the closing mustache for a given number of open mustaches.
Definition at line 25 of file check_redundant_namespace_qualifiers.py.
def check_redundant_namespace_qualifiers.is_a_define_statement | ( | match, | |
body | |||
) |
See if the matching line begins with #define
Definition at line 65 of file check_redundant_namespace_qualifiers.py.
def check_redundant_namespace_qualifiers.update_file | ( | contents, | |
namespaces | |||
) |
Scan the contents of a file, and for top-level namespaces in namespaces remove redundant usages.
Definition at line 73 of file check_redundant_namespace_qualifiers.py.
|
private |
Definition at line 144 of file check_redundant_namespace_qualifiers.py.
|
private |
Definition at line 113 of file check_redundant_namespace_qualifiers.py.
|
private |
Definition at line 123 of file check_redundant_namespace_qualifiers.py.
list check_redundant_namespace_qualifiers.changed = [] |
Definition at line 146 of file check_redundant_namespace_qualifiers.py.
check_redundant_namespace_qualifiers.Config = collections.namedtuple('Config', ['dirs', 'namespaces']) |
Definition at line 142 of file check_redundant_namespace_qualifiers.py.
check_redundant_namespace_qualifiers.contents = f.read() |
Definition at line 156 of file check_redundant_namespace_qualifiers.py.
def check_redundant_namespace_qualifiers.output = update_file(_TEST, ['foo']) |
Definition at line 133 of file check_redundant_namespace_qualifiers.py.
Definition at line 153 of file check_redundant_namespace_qualifiers.py.
def check_redundant_namespace_qualifiers.updated = update_file(contents, config.namespaces) |
Definition at line 159 of file check_redundant_namespace_qualifiers.py.