Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

docs: automarkup: Remove some Sphinx 2 holdovers

Remove a few declarations that are no longer doing anything now that we
have left Sphinx 2 behind.

Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>

+2 -16
+2 -16
Documentation/sphinx/automarkup.py
··· 23 23 RE_function = re.compile(r'\b(([a-zA-Z_]\w+)\(\))', flags=re.ASCII) 24 24 25 25 # 26 - # Sphinx 2 uses the same :c:type role for struct, union, enum and typedef 27 - # 28 - RE_generic_type = re.compile(r'\b(struct|union|enum|typedef)\s+([a-zA-Z_]\w+)', 29 - flags=re.ASCII) 30 - 31 - # 32 26 # Sphinx 3 uses a different C role for each one of struct, union, enum and 33 27 # typedef 34 28 # ··· 144 150 return target_text 145 151 146 152 def markup_c_ref(docname, app, match): 147 - class_str = {# Sphinx 2 only 148 - RE_function: 'c-func', 149 - RE_generic_type: 'c-type', 150 - # Sphinx 3+ only 151 - RE_struct: 'c-struct', 153 + class_str = {RE_struct: 'c-struct', 152 154 RE_union: 'c-union', 153 155 RE_enum: 'c-enum', 154 156 RE_typedef: 'c-type', 155 157 } 156 - reftype_str = {# Sphinx 2 only 157 - RE_function: 'function', 158 - RE_generic_type: 'type', 159 - # Sphinx 3+ only 160 - RE_struct: 'struct', 158 + reftype_str = {RE_struct: 'struct', 161 159 RE_union: 'union', 162 160 RE_enum: 'enum', 163 161 RE_typedef: 'type',