Coverage for src/rejuvenation/cpp_clang_lst_example.py: 0%

6 statements  

« prev     ^ index     » next       coverage.py v7.17.0, created at 2026-11-16 16:04 +0000

1# Copyright (C) 2024-2026 TNO 

2# 

3# Licensed under the terms specified in the LICENSE file in the root directory 

4# of this repository, also available at: 

5# https://github.com/TNO/Renaissance.Py/blob/main/LICENSE 

6 

7"""AI: Example script demonstrating parsing and visualizing C++ source with the Clang LST adapter.""" 

8 

9import clang 

10 

11from renaissance.integrations.clang.clang_adapter import ClangAdapter 

12from renaissance.syntax_tree import ASTShower 

13 

14adapter = ClangAdapter(clang.__file__.replace("__init__.py", "native")) 

15lst = adapter.parse("features/targets/cpp_example.cpp") 

16 

17ASTShower.show_node(lst.root)