mirror of
https://github.com/AdaCore/langkit.git
synced 2026-02-12 12:28:12 -08:00
Merge branch 'mr/pmderodat/stylechecks' into 'master'
langkit.stylechecks: update for Python 3.14 Closes #984 See merge request eng/libadalang/langkit!1477
This commit is contained in:
@@ -772,13 +772,14 @@ class PythonLang(LanguageChecker):
|
||||
elif (
|
||||
isinstance(node, ast.stmt)
|
||||
and isinstance(node, ast.Expr)
|
||||
and isinstance(node.value, ast.Str)
|
||||
and isinstance(node.value, ast.Constant)
|
||||
and isinstance(node.value.value, str)
|
||||
):
|
||||
# Sometimes we use docstrings on local variables, and
|
||||
# ast.get_docstring does not allow us to catch that.
|
||||
# Instead, process all string literals that appear at
|
||||
# the root of a statement.
|
||||
raw_docstring = node.value.s
|
||||
raw_docstring = node.value.value
|
||||
docstring, lineno_offset = preprocess_docstring(
|
||||
raw_docstring
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user