mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
C++, add debug config variables
This commit is contained in:
parent
63457c700c
commit
5a2942be1e
@ -3722,8 +3722,8 @@ class LookupKey:
|
|||||||
class Symbol:
|
class Symbol:
|
||||||
debug_indent = 0
|
debug_indent = 0
|
||||||
debug_indent_string = " "
|
debug_indent_string = " "
|
||||||
debug_lookup = False
|
debug_lookup = False # overridden by the corresponding config value
|
||||||
debug_show_tree = False
|
debug_show_tree = False # overridden by the corresponding config value
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def debug_print(*args: Any) -> None:
|
def debug_print(*args: Any) -> None:
|
||||||
@ -7383,9 +7383,18 @@ def setup(app: Sphinx) -> Dict[str, Any]:
|
|||||||
app.add_config_value("cpp_paren_attributes", [], 'env')
|
app.add_config_value("cpp_paren_attributes", [], 'env')
|
||||||
app.add_post_transform(AliasTransform)
|
app.add_post_transform(AliasTransform)
|
||||||
|
|
||||||
|
# debug stuff
|
||||||
|
app.add_config_value("cpp_debug_lookup", False, '')
|
||||||
|
app.add_config_value("cpp_debug_show_tree", False, '')
|
||||||
|
|
||||||
|
def setDebugFlags(app):
|
||||||
|
Symbol.debug_lookup = app.config.cpp_debug_lookup
|
||||||
|
Symbol.debug_show_tree = app.config.cpp_debug_show_tree
|
||||||
|
app.connect("builder-inited", setDebugFlags)
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'version': 'builtin',
|
'version': 'builtin',
|
||||||
'env_version': 2,
|
'env_version': 3,
|
||||||
'parallel_read_safe': True,
|
'parallel_read_safe': True,
|
||||||
'parallel_write_safe': True,
|
'parallel_write_safe': True,
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user